Most common issues with 2FA is Google Authenticator app is not synced correctly. To make sure that you have the correct time in your Google Authenticator app follow the instructions given below.

On Android:

Go to Setting in Google Authenticator

Select  Time correction for codes

Click on Sync Now

On iOS

Go to Apple iPhone setting

Select General

Select Date & Time

Enable Automatically

Incase, Its already enabled, disable and re enable it after few seconds.