implemented red/black tree insertion