The villain should have a clear motive. Maybe they're seeking revenge for something in the past. And they should be smart, able to outwit the protagonist at times. For example, in 'The Silence of the Lambs', Hannibal Lecter is extremely intelligent.
A memorable villain often has a grand plan. It's not just about random acts of evil. They are planning something big and complex. Their personality should be charming in a way, so that other characters in the story might be deceived by them. For instance, the Joker in Batman stories has a chaotic charm. Their dialogue should also be interesting. They can say things that are both menacing and thought - provoking. This makes them stand out and be remembered by the readers.