This is usually related to 2-step authentication. Something you can test out easy: generate a google app password and use that instead of your normal account password.
More details here: https://www.uipath.com/kb-articles/enabling-email-activities-for-gmail
Hope this helps.
Mircea