Science is the best way to understand a world ruled by unintelligent, perfectly predictable forces. What is the best way to understand a world that is alive and filled with life, in which everything has its own will, and in which reality is a constraint imposed by beings of infinite power? In such a world you must be both a shepherd and a parasite, taking nourishment from the weak, stealing power from the strong, and devising new tricks to use against competitors.
Controlling the weak, attracting the patronage of the strong, and competing always with rivals? These are the behaviors of witches and wizards.