Added add child to index

Hi as discussed an extra public method and I refactored the logic into an overloaded private function. Hopefully it is okay...