in current entrerprise setup the device code flow and the Personal Access Tokens are being depreciated for security reasons. CyberSec teams prefer the interactive flow that can be better controlled with MFA and so on.
However, most users are using gh from a remote machine with vscode for instance so they would need to initiate port forwarding from their IDE to the actual remote HTTP server that is started by gh auth login before the authentication attempt.
The current implementation chooses a random port in bindLocalServer in https://github.com/cli/oauth/blob/main/webapp/local_server.go .
Being able to use redirect port from the command line or an environment variable would enable developpers to pre-configure port forwarding to achieve interactive logon with Oauth.