Can the location of the inductor on the board affect the operation of the microcontroller?
Microcontrollers are not very sensitive to noise, unless you really care about ADC noise.

Still, it is important to put it in the right place. This is not really about flux, as this inductor is shielded and will not radiate that much, rather it is about general layout. The inductor is a large part so its placement will influence the rest of your layout quite a lot. In a buck DC-DC the current switches quickly between two loops:


When the switch is ON this will be GND -> Input cap -> LM2596 -> inductor -> output cap -> GND
When the switch is OFF this will be GND -> Diode -> inductor -> output cap -> GND


So:


Priority #1: Connect input capacitor GND and diode GND at the same place in the ground plane to avoid routing square wave chopped current through ground. If you forget to do this you can get lots of ground noise.
Priority #2: Connect input cap GND and output cap GND close together on the GND plane to keep the inductor current in a short loop too. This current is a sawtooth, so it is less problematic than a square wave, but still nasty.
Keep your loops small, as emission depends on loop area.
Remember a DC-DC is always noisy, so don't put it between two connectors for example. GND noise generated by the DC-DC can cause both connector GND pins to be at different potentials, and if you add wires, you get a nice antenna. Better put it in a corner, with all the connectors on only one side of it.