adds bsontype to the id property.