The main function of DNS is to map names to IP addresses. Although machines are perfectly fine with using numbers to communicate, people aren't (especially with the gazilion of Internet devices these days).
But DNS is not just a server with records for other servers. The DNS system spans the globe , and is comprised by a hierarchy of organisational units, resembling a tree. At the root, there is ICANN, a nonprofit organisation responsible for policy, creation and management of new top-level domains (such as .com, and .uk) as well as for operating the root name servers, and managing the IPv4 and IPv6 address space.
Then there are the top-level domain registries (companies like VeriSign) which own and sell "in bulk" top-level domains to the registrars, which organisationally fall under them. Domain registrars are the companies you go to buy a domain for your website.
At the final level of the organisation, there is the domain (which you are responsible for) and its records. The nameserver that you select to hold the records of your domain, is called the authoritative name server. Meaning that it is this nameserver that holds the "official" records for your domain.
The DNS protocol describes a lot of different records for different purposes but the most common ones you will work with are A, CNAME, and MX records:
Address (A)
The Address (or simply A) record, is probably the most fundamental and widely used. It is the one that maps names to IP addresses. For example, the following record:
yourwebsite.com. IN A 23.9.62.14
will map the domain yourwebsite.com to IP address 23.9.62.14. The IP address is usually given to you by your hosting provider.
Note: Pressidium websites need two (2) A records and not one.
Canonical Name (CNAME)
The CNAME record is used to create a host alias. This is typically used when you need to have multiple hostnames (www,ftp,mail) to point to the same domain. For example, the same server could also be responsible for ftp, or mail. For example:
www IN CNAME yourwebsite.com.
will create an 'www' alias to yourwebsite.com, so that when someone connects to www.yourwebsite.com, will be redirected to yourwebsite.com.
Mail Exchange (MX)
The MX record is used to define the A record that will handle all incoming email for that domain. For example, if you want mail.yourwebsite.com to handle all mail addressed to yourwebsite.com , you use the following MX records:
website.com. MX 10 mail.website.com
website.com. MX 20 mail-backup.website.com
The number next to the MX string corresponds to priority. If for some reason mail.website.com becomes unavailable, then all mail will be handled by mail-backup.website.com.