You can see the options you have in the documentation article Recover an account with 2FA. If none of those work you can still try to contact GitHub support, but they might not be able help, as the documentation warns:
For security reasons, GitHub Support may not be able to restore access to accounts with two-factor authentication enabled if you lose your two-factor authentication credentials or lose access to your account recovery methods.
Good luck!
Request for GitHub Account Recovery Assistance
Lost access to 2FA—how can I recover my account?
My main account is locked due to 2FA without having recovery codes, how can I recover it?
How to recover/reset github recovery codes.
Videos
After changing jobs, I had to return my computer and phone, which means I no longer have my recovery codes or the device with my TOTP setup.
I still have my password and access to my email, but I’m unable to pass the 2FA verification. Is there a way to reset it, maybe by reaching out to Support or a non-automated service?