model: fix saving with a compound key

MongoEngine was generating a new ObjectId when saving the original
object which was preventing the versioned document saving correctly in
the database.