There are organizations that are called registries that manage each TLD option. When you register domain names, you would first visit a domain registrar who would in turn check with the registry that manages that TLD to see if the domain is available. If the domain for the TLD you want discovers that it is in fact available, the registry adds it to their registry and gives you access to it. If the domain has already been registered by another user for that TLD, you will be shown during the domain registration process that the domain isn't available.

Don’t get discouraged in your domain name search if what you’re looking for is already taken. We have a couple of ways for dealing with such a situation. You can try our Domain Buy Service, where we negotiate acquiring the domain from its current owner. We also offer a Domain Backorder service, where you purchase a backorder credit to give you a chance to get the domain when it goes into auction.
SnapNames is a web domain name marketplace - meaning that they only deal specifically with domains that are currently owned by somebody else. They offer daily and premium auctions, private brokerage of domains, and buy-it-now listings for buying and selling domain names, including over 30 million domain names that aren't all, as you'll find on some services, exorbitant. They have over three million customers, including a significant number of small businesses, which is worth it.
What’s easy to forget, though, is that Verisign have managed .com for the past 20 years without so much as a hiccup of disruption or downtime, and that there’s no guarantee that a more democratic or competitive process would have resulted in the 2 decades of .com stability that we’ve enjoyed. Internet governance is obviously important, but we should remember that the overwhelming majority of users don’t know or care what’s going on behind the scenes.
HostGator is a company I used for many years with an old firm, and I've found them to be fairly reliable as a rock-solid grounding for a bandwidth-heavy site. Their control panel is also fairly powerful, allowing you to automatically control your fleet of names, as well as locking them down so that nobody can snipe them if you accidentally let a renewal lapse. Their prices are competitive but not the best, but I've found them to be immensely reliable in the past.  Read our HostGator Review.
Not every registrar sells every top-level domain, so if you want an uncommon TLD like .pizza, you might have to try a few registrars. Unusual TLDs often cost more than a standard .com address, but provide built-in memorability and give you more name options, since far fewer .pizza addresses are already taken. You can check name availability at any registrar that offers the TLD you want.

Every time you visit a website, your computer performs what's called a "DNS lookup". When you manage a domain with us, you get to use the same DNS servers as Google. This means your domain name will connect quickly and reliably to your website. We include 10 million resolutions per year for each domain you register with Google Domains. Learn more in the Help Center.
If you ever change your web host (the actual physical location of your website files), your domain name goes with you. Your regular visitors or customers who knew your site name as (say) would not have to be informed about a change of web address (also known as "URL"), since as far as they are concerned, the site is still at the same place. They would simply type your domain name and they'd be transparently brought to your new location.
Domain name search results appear as you type. We can do domain lookups very quickly, and usually show domain search results in less than 100 milliseconds. We generate domain names and check domain extensions instantly. We use artificial intelligence techniques to find domains for sale that you can buy today and expired domains to backorder. Just start typing!
A domain name is an identification string that defines a realm of administrative autonomy, authority or control within the Internet. Domain names are formed by the rules and procedures of the Domain Name System (DNS). Any name registered in the DNS is a domain name. Domain names are used in various networking contexts and for application-specific naming and addressing purposes. In general, a domain name represents an Internet Protocol (IP) resource, such as a personal computer used to access the Internet, a server computer hosting a web site, or the web site itself or any other service communicated via the Internet. In 2017, 330.6 million domain names had been registered.[1]