The Issue
I recently had an issue trying to add a new Azure DevOps Pipeline Agent Pool to an existing Azure DevOps 2022 Server via the Team Project Collection Settings UI.
When tried to add the agent pool I got the error
Access denied
needs Manage permissions to perform this action. For more information, contact the Azure DevOps Server administrator
The problem was that I was the Azure DevOps Server administrator
The Solution
The answer was to create the new Agent Pool at the Team Project level.
The difference when creating the new Agent Pool at the Team Project level is that though you can see the new Agent Pool at the Team Project Collection level, it is only usable in the Team Project it was created in.
For any other Team Projects, you have to add the newly created Agent Pool as an ‘Existing Agent Pool’ via the Team Projects > Settings > Agent Pool menu
So why did this work?
My assumption is that in one or more Team Projects in the Team Project Collection there are some custom permissions that deny access to the Agent Pool settings.
As adding a new Agent Pool at the collection level tries to add it to all existing Team Project, any such deny permission could cause the error I was seeing.