GMAIL configuration

I tried to configure my ERPNEXT instance to use my company email account (which is in gmail servers), to send emails to my customers. The problem I get, is that gmail is not allowing me to send attachments (pdf files). So to solve this, I installed my own email server, but my mails are getting sent to SPAM. Can some one point me to a solution for this issue?

Sorry for the posr. It seems that I made one mistake before, because now it is working fine with GMAIL server