When you create a VM, The IP resource for the VM is already created. Although, Azure does not create a Fully Qualified Domain Name, which is something that can be created after the VM is deployed.
To create an FQDN, Go to the VM -> Under DNS name, 'Configure' -> Enter the required DNS name and Click on save.
You can now use that DNS name to connect with the VM remotely.
Also, learn more about Azure, and become a master by enrolling in Intellipaat's Azure Online Training!