Walking is a safe and good way to lose weight, especially at the beginning of the weight loss journey. Excess weight puts a lot of strain on the leg and back joints, which are easily damaged with higher impact sports and exercise programs.
However, as with any exercise program (and especially to lose weight), the lengths, difficulties and speed of the walks should be varied, both to keep interest and to provide a challenge to the body.
Over a span of 5 years I lost 30kg+, with my only (cardio) exercise being walking. I did very long walks on weekends, increasing the difficulty when I felt I could handle it, and walked one hour each week day, more when I had the energy, replacing part of my bus/train commute to work.
Of course, I shifted to a healthier diet as well (less sugar, less fat, more fresh vegetables and fruit, and a higher percentage of protein).