How to sign out from two factor authentication and then again sign in with the Apple ID used with secondary authentication .
( a ) Open system preferences and click on iCloud , click on sign out , a pop up window appears keep the box of iCloud Drive , contacts , calendars , reminders as checked and click on keep a copy .
Immediately click on stop updating and continue , so on the next pop up click on continue with sign out , the circle rotates .
( b ) Enter your 2FA id password and click on continue , circle rotates , wait for a while and it will stuck and have patience , you can see a red notification have encircled 1 over system preferences in the dock , take cursor on top menu bar and hover over system preferences you can see SBBOD , after a while a preferences error will be shown stating there was an error in iCloud preferences , click on ok .
( c ) Now open system preferences , click on iCloud in the window you will see update Apple ID settings , some account services will not be available until you sign out again ( having a yellow exclamation mark ) , click on continue .
( d ) Again it will show update apple settings , some account services will not be available until you sign in again , click on continue .
( e ) Enter your 2FA id password and click on ok .
( f ) enter your Mac password to continue in the next window , so enter your admin password and click on ok , after a few minutes the pop up error will go away .
( g ) Check the box of the keychain and in front of it no option button will be shown as it is 2FA .
when the user has set up secondary authentication account there is always an option button in front of keychain , this is the basic difference .
( h ) Check the box of photos and iCloud Drive , it will show setting up a small circle rotates , wait for a while and then click over options button every box in the upcoming window is checked and click on done , also check the box of Siri a pop up appears do you want to merge your bookmarks and reading list with iCloud , click on ok the box for safari that was dimmed will turn on .
Finally 2FA is set up with all the boxes as checked and you can see your Apple ID used with it in the location system preferences - iCloud .
I have asked what Mac operating system is used click on apple logo > about this Mac > is it Mac OS catalina 10.15.7 or earlier versions .
The error showing Apple ID verification failed you have skipped the steps when signing out the secondary authentication account and then signed in 2FA .