The treehouse, built to help an autistic boy deal with anxiety, will be demolished by a council.