In Microsoft Teams it is required to create a resource account for auto-attendants and call queues to be able to route phone numbers or auto-attendents to them. In the PBX world this would be considered an Inbound rule/route.
Side Panel > Org-wide settings > Resource Accounts
name of queue or auto attendent
we use the same as Displayname @
Resource Account Type:
Auto Attendant or
Now that you have created your resource group you need to assign a phone number, for direct routing we will do this via PowerShell
firstname.lastname@example.org to the resource account user
1NPANXXYYYY to the phone number you want assigned to your phone number
Set-CsOnlineApplicationInstance -Identity "email@example.com" -OnpremPhoneNumber "1NPANXXYYYY"