If you've just added an IMAP email account to your iDevice and find you can't delete mails...
1. Press the Home button and choose Settings.
2. Scroll down and click Mail, Contacts, Calendars.
3. Tap your email account.
4. Scroll to the bottom and click Advanced.
5. Scroll to the bottom and tap the empty IMAP Path Prefix.
6. Enter INBOX in capitals, then click ‘Accounts’ at the top left and click ‘Done’ at the top right twice to close the settings.
7. Press the Home button and then re-open Mail.
8. You will now be able to delete or move your emails on your iPhone