I recently messaged apple support regarding this issue and they recommended that I should restore the app that had the bundle that I want to reuse, assign it another bundle and then go to the developer portal and delete it from that account. This way I can switch to the new account that I want to add this bundle id and register the certificate with the same name.
These are the steps that I followed:
Restore the app that you want to remove from your current appstoreconnect account
You can see how you do that here: https://help.apple.com/app-store-connect/?lang=en#/dev28d17ed35
Find your recently restored app in the dashboard, go to General > App Information, and assign a new bundle id to your app - anything that is not the one you want to delete
Go to the developer portal and then under Certificates, Identifiers and Profiles > Identifiers, locate and delete the certificate
Now, if you go to the other account in the developer portal, you will be able to create a new certificate with the same name as the certificate you just deleted!
Lastly you just need to go back to the appstoreconnect, and then create the app with the bundle id from the newly created certificate.