AL8860 Led Driver: inductor placement
You are ignoring parasitics. By keeping the inductor close to SW, you insure that the high dV/dt node (SW) does not have extra parasitic capacitance which might lead to unwanted resonances or cause you to fail radiated emissions, etc. This is really the answer to both of your questions. You can swap positions between the LED's and inductor IF you keep the SW node (and all LED nodes) very short. But it is less optimal than putting the inductor right next to SW.

It is a good question though. If you naively look at the schematic only and give no consideration to parasitics from the layout, then for sure you can swap the positions of the inductor and LED's. The regulator would never know the difference. And in the real world, it would probably work to some extent. I mean, the LED's would still light up and be regulated, etc. There would just be side effects or potential side effects due to parasitics.

In the real world, reducing the length of high dV/dt nodes is a good idea.