I'm interested in a good general overview.
How does iMessage actually work?
In a nutshell, iOS sets up a persistent connection to the Apple Push Notification (APN) servers if you elect to use iMessage, iCloud, Notifications or other push services. From there, the phone checks in with the servers anytime it has a network connection and listens for messages that the servers wish to push to your device. Furthermore, iOS then registers which applications on your phone should get specific messages. All the messages pass through the notification center system in case you have elected for them to be posted to specific places such as the lock screen, the notification tray or just passed off to the end application for each message as appropriate.
From a user perspective, this article should answer any questions you may have about iMessage:
This is a more technical explanation of how Apple's Push Notification system works: