Added support for serializing mongo::OID

Also ensured that __version__ gets added at the end of mongo documents
instead of the beginning, because mongo prefers _id to be at the
beginning for performance.