Apple Mail removes my emails from inbox
Debugging Mail.app on OS X is fairly easy - especially in the case you describe where the problem is with one account.


Get the Incoming Mail server name from preferences (Mail --> Preferences... --> Accounts --> (your account) --> Incoming Mail Server) - it's likely something like mail.gmail.com or imap.gmail.com
Quit Mail
Open terminal and type this all as one long line (it's split here for readability):

/Applications/Mail.app/Contents/MacOS/Mail -LogActivityOnHost imap.gmail.com -LogIMAPErrors YES >&amp; ~/Desktop/MailConnection.log &amp;


The harder part becomes making sense of the volume of data being logged, but again it seems you have a good handle on the scope of the issue. I would take a gander at your IMAP and label settings in gmail preferences to be sure your account isn't suppressing those folders for IMAP delivery.