One thing you learn early on when you work with complex systems is that you can’t build anything and expect it to work the first time.
A novel very much is a complex system. The setting, characters, and plot intertwine around each other, effecting each other and being effected in turn. This means that you can’t just sit down and write one without writing the others, and you can’t know one without knowing the others.
I know that sounds tautological but stay with me.
The only way to deal with this kind of situation is the iterate. First you define your plot, setting and characters as best you can, but not defining them so much as to stifle yourself. Then you start writing, or outlining depending on how you work. You know that parts, maybe even large parts, will be unused. You accept that because the first draft’s only purpose is to get your second draft.
On your second draft you have a better understanding, you can move things around and can work with a finer hand then before.
Don’t be afraid if you don’t have a lot of details when you start, there is nothing wrong with finding your characters as you go, or even changing the direction of the plot. There are two major events in my first outline that never made it to the first draft, I only realized when writing that they were mistakes.
The first one was unnecessary and would add bulk where I wanted to build momentum. The second was cool in theory but my main character would not be doing much but watching, he had no useful skills in that situation.
As you go forward things like that will happen to you, you’ll see mistakes you did not see before, and each time you go through the book you will get a better handle on it.