"Tidak" is negation in general. "Bukan" is an adverb to denote a choice of not this but that. It is used in situations where there is an alternative to the one in question.
Not me but him = Bukan saya, tapi dia. That is not my house, it's theirs = Itu bukan rumah saya, itu punya mereka.
I am not happy = Saya tidak senang. I am not happy, but sad = Saya bukan senang, tapi sedih.