Does your story need a good villain? Villains can be a little tricky sometimes due to the fact that you are a good person. So here are some basic ideas that I have found helpful in my own story writing and role playing.
1. Villains are purposeful. A villain needs a purpose to act. Does he want something? Maybe he loves someone. Maybe he want to rule the world. Maybe he is bored and wants chaos for a while. Give the villain a purpose and let that run his decisions.
2. Villains are proactive. Villains act while heroes tent to react instead. Villains make their own story. If they want something, they work at taking it. They set their plans in motion instead of waiting for things to come to them. This also means that they will do what they can to have backup plans and remove obstacles, including people. This is often how the hero gets involved.
3. Villains (unintentionally) give heroes a chance to prove themselves and thwart them. Many villains have elaborate schemes that are needlessly complicated, like having a devise to control all the sheep in the world with a beam that can only be activated under the light of the harvest moon. They might also have a large dungeon filled with monsters and minions to help the hero understand how to fight the villain in his final chamber. They monologue, telling backstory and how to defeat them (unintentionally again, of course).
4. And last, villains are bad people. They may have started with good intentions, but used evil means to reach their end or they might be doing good causes for bad reasons, but in the end, they are on the wrong side. This is usually due to selfishness but any vice works. In writing a villain, it is important to remember that the value of the hero is based on the villain. This means the hero has the opposing virtue. If the villain is bad enough, the hero can show his own quality as a contrast rather than a comparative.
I hope that this has helped give some definition to how villains function. Good Luck in your writing!
-The Mighty Q