Domain names are easy. You buy one from a vetted company, pay x sum every year to keep it (I pay about 10 USD/year for locitus.com) and then you administer it from the website of where you bought the domain name.
A-records points to your servers IP address
CNAMES point to an A record and serve as nicknames for A records (not really used much on public internet)
MX-records points to A records but are only used by E-mail servers, so point them to your A record "mail.example.com" and not www.example.com