Add 'pop' function to rbtree