Fix renaming a document that is in a children collection

fix #376

there are 2 cases: 

1. renaming a document in the same children collection. this works with this fix.
2. moving a document out of an initialized children collection by updating its id. there is now a test showing this does not work, and a second one showing that $dm->move works for that.