The answer is that the two are so interlinked it is difficult to say what comes first. The characters drive the plot but in order to create the characters you must have an idea what the plot is about.
In my case, in respect of the DI Andy Horton series of novels, this is usually a location and a victim, and along with that I will have a theme that I wish the crime novel to explore. Once I have this I then begin to create and develop the key characters, outside that is of my regular characters who appear in the DI Horton novels.
I start developing my characters using spider grams. I draw a circle and put each character in the centre of that circle and then I throw out lines and ask a series of ‘open’questions about each of them.
For example, if I have the victim in the circle I ask questions such as who is he? How did he get where he is? Why would someone want to kill him? Who killed him? How was he killed? What’s his background, family, education, experience? What’s his occupation? How old is he? Where does he live? What’s his personality? What does he look like? What has shaped him? How are the victim’s family, friends and others going to react? How do they see this character? What’s my main character (in my case my detective, DI Andy Horton) going to do next?
I draw up character profiles for each of the main and secondary characters, some might be sketchier than others. But that doesn't matter because once I start putting dialogue into their mouths and have them walking around and interacting with people they come alive and I can then begin to flesh out their characteristics and motivations. I can add to my notes and my storyboard as the characters’ actions start to drive the plot.
The surprises, twists and turns all spring from the characters' motivations and as I write I find ideas occurring to me that I hadn’t previously considered. I sometimes also discover that someone I thought was going to be a minor character turns out to be much more interesting and a major character can become boring and sometimes unnecessary, if that happens then I cut him or her out.
As I write I ask myself what will this character do in this situation. What will he/she do next? I throw out more lines around that spider gram. I continually ask questions about each character and answer them as the novel progresses. I shape and reshape them. I put them in difficult or unusual situations, and as I do the story unfolds and the tension builds.