I think it is because text is usually read left to right and is left aligned. You generally don't read your own messages, so makes makes more sense for them to be on the right (albiet left aligned on the right side, usually). For languages that are right to left, I would imagine it may be reversed.