Anecdotally, walking outside in a city or forest seems to work better for me than a treadmill, though this study seems to indicate it shouldn't make a difference. Lots of confounders there I suppose.
Maybe specifically for creativity there's no difference but other things (mood etc) benefit from getting outside.
I would find walking in a city to be a barrier to creativity. You have to keep engaging your concious, safety brain to deal with other pedestrians, road crossings and immunize your brain from all the advertising and noise that is trying to penetrate.
The ideal walking for me is somewhere outside with fresh air, but without constant interruptions to the flow of walking and thinking.
Ideally you want to be able to walk alone, but in a type of daydream where you're thinking about the problem at hand instead of spending many cycles on the process of walking. That means covering a well known route with few interruptions.
Luckily for me I have access to this type of environment right near my front door. But for those who don't, a treadmill could offer a similar experience, but I suspect the treadmill needs to be a good space (light, airy room, nice outlook from a window).
My guess is that walking around a city or a forest is more helpful to creativity because of the gradual change in environment. And there is a lot of evidence environment has significant effects on thinking and behavior.
Other studies have found high ceilings are good for creativity while low ceilings have a negative effect on creativity. I would imagine walking outside without any ceiling would be as good or better than a space with high ceilings.
I think it has more to do with engaging all your senses with the complexity of a natural environment. Many layers of sound, sight, smell, touch that are supressed indoors.
A good experiment would be trying an urban track, like you'd see stereotypically at a high school or some parks. Then you'd have the extreme artificial urbanism, yet also have the lazy "just walk the path no interruptions" of a trail.
I also walk at lunch time, also whenever shifting gears during the day, and hike on the weekends on trails, and I don't find a huge difference.
Maybe specifically for creativity there's no difference but other things (mood etc) benefit from getting outside.