Decide on the mystery that needs to be solved. A mystery that is strongly linked to the desires and needs of the hero will be the most functional.
Choose two or three characters to become entangled with the hero. They should all have opportunity and motive to have committed the wrongdoing.
Create a villain who is guilty of the crime. He should have motive, opportunity and a third characteristic which links him personally to the crime.
Create the red herring, or innocent, character. The red herring should share some qualities with the villain and should also possess motive and opportunity, however, there needs to be an exit strategy for proving the red herring's innocence.
Have the protagonist suspect the red herring of being guilty and build up a case against him or her.The longer that the protagonist believes that the red herring is guilty, the stronger the dramatic tension will be. Try to keep the red herring a mystery until the climax of the piece.