It is possible to loose weight with walking, dependent on starting fitness level and starting weight.
I gained a lot of weight when I was wheelchair bound during DD's pregnancy and after because my mobility was still so limited - also because I'm a stress eater and my ex was very abusive. So I was obese and extremely unfit. When I left ex I lost 5kg without trying then plateaued. Drs had put me on steroids by this point (which make weight loss very hard). The steroids however reduced inflammation and pain enough to start walking. So I started out with small brisk walks and gradually increased how far I went until I was doing 1.5-2miles a day. Due to my weight and fitness level this was actually really good moderate exercise for me, thus burnt a reasonable amount of calories. I lost a further 10kg without changing anything else, before plateauing again.
So whilst you can't walk (or run) off a bad diet, you can help yourself loose weight if your diet is now reasonable. Plus it's far healthier to get fitter, rather than just loose weight.