Google has finally equipped GMail with IMAP support. What does this mean? Here's an e-mail lesson courtesy of TheFeed.
GMail has used POP3 for e-mail access from cellphones and 3rd-party programs like Microsoft Outlook. With POP3 a user downloads a copy of the e-mail locally to their computer or device.
This means that deleting it won't delete it from the server. Reading an e-mail won't mark it as read on the server.
IMAP is synchronized across all devices and programs. That means if you read, send, or delete a message on an iPhone, it will appear in GMail correctly.
Here's a video that explains how to set this up on an iPhone (or any other mobile device).