He didn't buy twitter for data, he bought it to shut down criticism of himself and it worked
https://techcrunch.com/2023/04/12/elon-musk-admits-he-only-b...
Later, when he realized that this was a stupid idea and that his amazing business acumen resulted in him drastically overpaying, he tried to back out of the sale by giving the excuse that the number of bots/spam posts/etc were more than he thought. According to the agreement that he had signed, this was not a valid reason to back out of the deal. His lawyers advised him that he’d probably lose in court, hence he was “forced to” buy the site as your article states.