gmail account emails only appear in iCloud Inbox This has apparently been going on for some time but I didn't notice it until today.

I use Apple Mail (Sierra) as my mail client.  Any emails I receive to either of my two Gmail accounts, are only visible under the iCloud Inbox folder.  They are labeled as existing in that folder when I do a search, and I can see them as long as that's what I'm viewing (or have rules based on that Inbox).  But if I go to the actual Gmail account inboxes, none of the messages are there.

Why is this happening and how can I stop it?  I tried removing a Gmail account and re-adding it from scratch in System Prefs, but nothing changed.

To add some clarity, here is a picture showing my Inboxes - 1 for iCloud, and 2 for Gmail.  All emails sent to or from the Gmail addresses (via the mail.app client) appear under the iCloud Inbox (or sent mail) and do NOT appear under the appropriate Gmail Inboxes.

If I scroll down further, I see the second image, which clearly shows that the Gmail Inboxes don't even have all the usual Gmail folders below them, only Important and Chats, but nothing else.  So what gives here?
you might have an rule set-up to automatically forward mail in the client.