In a Microsoft Exchange Server deployment, internal URLs are returned by Autodiscover V2 even if your organization is using external URLs. This may prevent Microsoft Teams from synchronizing meeting information and prevents Exchange Online from synchronizing devices using cached Outlook mailboxes.
This issue is caused by an environment misconfiguration. Different servers may have different URL's to meet site requirements, but all servers internal and external URL's must be configured consistently.
Make sure that both internal and external URLs are present and configured consistently on all servers across sites.