No, it is not necessary or wajib, unless one had made a vow that should they purchase a new house they will sacrifice an animal.
Otherwise, they do not need to. Of course, it is highly recommended to show gratitude to Allah ta'ala, and thankfulness, and to repel envy or evil eye, by organising a banquet (waleemah), and by sacrificing an animal and feeding people. It does not need to be a goat, but any halal animal.
And Allah knows best