Gmail and the iPhone sync issue

I would like to know, is there a way that i can delete inbox messages on my iPhone, while keeping them in my gmail inbox, or archiving them in a folder?

Thanks in advance!
Go into the advanced setting and set the mailbox bavior.
Apparently i'm an idiot, i set the deleted behavior to on the server /starred, but the messages arent getting saved in there. Is there something else i should set, or am i just doing it wrong?

Original thread: https://forums.imore.com/threads/gmail-and-the-iphone-sync-issue.178206/