Welcome to the Microsoft Q&A Platform! Thank you for asking your question here.
I received the same error message when trying to create an Azure VPN Gateway. The problem was that I had not yet created the GatewaySubnet.
The solution for me was to create the GatewaySubnet first, Then the Azure portal allowed me to create the Azure VPN Gateway instance.
Refer this link how to create a Virtual Network Gateway:
https://learn.microsoft.com/en-us/azure/vpn-gateway/tutorial-create-gateway-portal#CreatVNet
If you have any further queries, do let us know.
Thanks,
Rohtih.
Please don’t forget to close the thread by clicking "Accept the answer" wherever the information provided helps you, as this can be beneficial to other community members.