@Jonathan1, did you manage to get this working?
I’ve just finished setting up my instance with a gmail account with no hiccups. The thread pointed by @dh024 from this community has plenty of information around it. In case you’re interested my settings are as follows:
globalSettings__mail__replyToEmail=my-email-address@gmail.com
globalSettings__mail__smtp__host=smtp.gmail.com
globalSettings__mail__smtp__port=587
globalSettings__mail__smtp__ssl=true
globalSettings__mail__smtp__username=my-email-address@gmail.com
globalSettings__mail__smtp__password=my-16-chars-app-password
And the app password was generated at the accounts settings as instructed by Google itself.