Dathan and Abiram were reincarnated as two bulls, which Elijah used in his competition with 450 prophets of Baal. Dathan was a more elevated soul, and his lot was to be a sacrifice to God. But Abiram was not on such a level, and his lot was to be sacrificed to Baal. Abiram did not want that. Elijah had to whisper in his ear that he, too, would serve a good purpose - by not being accepted.
Now, compare the two incarnations. Dathan and Abiraam were burned by fire from Heaven for trying to advance their selfish goals. As two bulls, they did it right. They were also burnt by fire from Heaven, but this time, Elijah used them as a sacrifice to God.
Art: Cows Resting by Rosa Bonheur