I was trying to push my new repository to my Github and the permission was denied because I was trying to push it to my old workplace's account.
But it took some time to find the right solution for me so I wanted to leave here.
If you attempt all these steps and your terminal says like this
remote: Permission to harukakato35/StressBox.git denied to ○○○. fatal: unable to access 'https://github.com/harukakato35/StressBox.git/': The requested URL returned error: 403
Try this as the quickest way.
git push email@example.com:harukakato35/StressBox.git main
Or with this way, you can connect with the account you want
$ git remote set-url origin https://firstname.lastname@example.org/hoge/abc.git $ git push origin main
Hope this is useful for you!