I no longer have this phone listed as a device.
You can add that iPhone to your device list, see this Apple article:
Check your Apple ID device list to see where you're signed in
https://support.apple.com/en-us/HT205064
I want to switch back to the 12 Pro Max but it is passcode disabled
See this Apple article: If you forgot your iPhone passcode
https://support.apple.com/en-us/HT204306
Or use account recovery, see the following Apple articles:
Set up an account recovery contact
https://support.apple.com/en-us/HT212513
How to use account recovery when you can’t reset your Apple ID password
https://support.apple.com/en-us/HT204921
Help a friend or family member as their account recovery contact
https://support.apple.com/en-in/HT212515