added a function to add a group to a parent group