Even though you are using IMAP, I believe there is an option somewhere to delete the message from the server (either upon checking/reading the message(s), or at a predetermined interval). So, you'll want to comb through your email preferences (on both devices), go line by line, don't miss a thing, and see if somewhere you have a "delete from server" preference checkmarked/chosen somewhere.