change tree structure