About AWS and GoDaddy

I need some server space for a new website and was looking into AWS and GoDaddy. As I understand, GoDaddy allows you to buy a domain (like www.example.com) and hosting space whereas AWS just gives you hosting space. Am I right? Please correct me.

I need to buy a domain and need hosting space and would like to know the best way