This is interesting, and certainly must relate to 1&1 in some particular way. With On My Mac mailboxes, when you delete a message, Mail automatically creates a separate Trash mailbox for On My Mac. The cycle for that one trash is set for one week and is not under user control.
However, if you see both the Trash folder and Deleted Messages folder when using Webmail access, then On My Mac should NOT be involved.
In the Finder, please open Home/Library/Mail, and first open the IMAP account folder for 1&1 to observe whether there is a Deleted Messages.imapmbox folder somewhere within this account folder? Next open the Mailboxes folder within the Mail folder, and see what, if any, mailboxes are there (in the form xxxx.mbox) related to this account?
Ernie