Hi,
are your Mail-Settings working on different Apps? There are a number of things that might be wrong. For example most modern mail providers use separate „app passwords“ or in a more clear term a smtp password thats different from your normal imap or pop password. It‘s been a while but I think it is also that way for gmail.
Other than that, the encryption method and ports can be weird sometimes as the might be labled differently.
You could look into /var/log/mail.log for more details on what is actually happening in the background.