Migration tool fixes

:warning: WIP

This fixes various issues that have come up with the migration tool over the past couple of weeks.

- Make sure records are always given a string `_id` (rather than defaulting to an ObjectId) #295 #300
- Make sure memberships refer to the `_id` field of related records, rather than embedding them as JSON #298 
- Prevent the slug from changing when a record is edited #296 

Still to be done before this is merged:

- [ ] Ensure documents are indexed in elasticsearch #297 

Closes #295 
Closes #296 
Closes #297 
Closes #298 
Closes #300