The hostname of your server does not need to match the domain name from which you can reach it from the Internet. I'm guessing you're trying to set up this server as a web server or otherwise hosting some service available from the Internet.
Your domain name has DNS name servers associated with it; you need to configure those name servers to respond with your Linux server's public IP address when queried. Most likely, you can do this through your registrar's control panel since some registrar's will host DNS for you.
For example, if your server can be reached from the public Internet at IP address 184.108.40.206, then you would want to configure DNS so requesting the
A record for
server.example.com responds with