Mail (Mountain Lion): If messages aren’t stored where expected on the mail server
If you have an Internet Message Access Protocol (IMAP) account and you set the account preferences to store copies of messages (draft, sent, junk, or trash) on the IMAP mail server, you might experience situations in which your messages aren’t stored where you expected on the mail server. For example:
When Mail stores messages on the server, it looks for specific mailboxes, by name, in which to put the messages. If Mail doesn’t find those mailboxes on the server, it tries to create them on the server or, failing that, on your Mac.
If there is another mailbox on the IMAP server (for example, Sent Items) that contains the messages you’re looking for, you can have Mail use that mailbox to store messages. To do so, select that mailbox (listed under the account’s name and icon) in the Mail sidebar, choose Mailbox > Use This Mailbox For, and then choose Drafts, Sent, Trash, or Junk, as applicable. You can select any mailbox on your IMAP server to store draft, sent, deleted, or junk messages. If Mail can’t upload messages to a server mailbox, copies of the messages aren’t saved.
If you change the account preferences to no longer store copies of messages on the mail server, you’ll see that messages aren’t where they used to be. For example, if you were saving sent messages on the server and then change your settings to save those messages on your Mac, the Sent mailbox changes to contain only messages stored on your Mac; messages that were stored on the server no longer appear in that mailbox. Instead, you’ll see that those messages are now located under the account’s name and icon at the bottom of the list of mailboxes in the Mail sidebar, in a mailbox called Sent Messages.
Similarly, if you change from saving sent messages on your Mac to saving them on the server, the Sent Messages mailbox changes to contain only messages stored on the server. You’ll now see the messages that were saved on your Mac in a mailbox called Sent Messages, followed by the account name in parentheses, such as Sent Messages (Gmail Account).