You just need to use "Is element exist" and determine if current
log in requires recovery email or not.
One possible solution is to work in stages. Firstly just build
a simple bot that will only log in to g account for the first time.
And at this stage implement that "Is element exist" and save
that logged in state by saving that profile for later use.
In second stage all your accounts will be already logged in, so
it would be lot easier and simpler to just change passwords for
all of them. In this second stage you wont need to worry about
logging in with or without recovery email any more.