A key ingredient to a good story is to make sure your antagonist is fantastic. They need to be stronger than the protagonist, they need to evoke empathy in the reader, and they need to have a believable plan.
To give the antagonist a great plan, ask “what will the positive consequences of the antagonist’s plan be, if they are successful?”
Yes, you heard right. The positive effects of the villain’s plan.
There are several types of conflicts where this isn’t hard to answer. If the villain and the hero are competing against each other in some form of zero-sum game, then the villain will be the winner if their plan succeeds.
If you can convince your reader that the villain believe in their plan, and believe it will make some part of the world or their world a better place, the reader will believe in the villain and their plan, and while they might not agree at all, they’ll understand where the plan comes from, and that understanding is crucial to believing in the antagonist.
Of course, if you want to go into very deep water with a villain that for instance decides to solve global warming by killing off half the population, you have a much harder work to both motivate the villain’s thinking and keep them empathetic to the reader.
I think the most important function of an antagonist is to show that however evil they are, what they do falls within the boundaries of the human condition. Given the right circumstances, it could be you or me. And it is in exactly that point of doubt the greatest chills from a fantastic antagonist comes.
If you want to write a good story, convince the reader they could be the victim of the murderer. If you want to write a fantastic story, convince them they could be the murderer.
Then, of course, the final step is to use story and the story world to show the reader why they would not want to be the murderer by showing the consequences of being a villain. The villain is, after all, the antagonist of the story.

