For the tagging part, since I found it sometimes has a problem even on the server side. For example, Gmail does not set the "Draft" flag well, and that's why I can not implement the edit draft functionality, as discussed in the following issue.
I already reported the problem the GMail. And also some Chinese mail providers even do not handle read flag very well, if I mark a email as read and then mark it as unread again, the message still has "Seen" flag setted.
Maybe if I could find a reliable way in the future, I counld add the customized tagging an a feature in future release