Can you share your configuration? According to the docs, you may:
Create PAT with permissions for source code in the tools project (check selected organizations during creation): Use personal access tokens
Create Azure Repos/Team Foundation Server service connection: Manage service connections
Use it in pipelines: Repository resource definition
resources:
repositories:
- repository: MyAzureReposGitRepository # In a different organization
endpoint: MyAzureReposGitServiceConnection
type: git
name: OtherProject/MyAzureReposGitRepo