It's difficult to walk on ice because there's very little friction between the bottoms of your shoes and the ice. Friction is a force that opposes motion. When your shoes push back on the ground the force of friction between the ground and your shoes pushes you in the opposite direction, propelling you forward. When two surfaces in contact are very smooth one doesn't push back much on the other. Ice has a very smooth surface, and it often has a thin layer of water on it. Since molecules in the liquid phase can move around freely water acts as a lubricant to fill in the imperfections in the surface and further decrease friction. This can result in your feet sliding out from under you instead of pushing off and moving you forward.
Shoes and boots with a traction tread that grip the ice provide more friction and make it easier to walk on ice. Also, picking one's feet straight up and setting them down helps as the placement of the feet then changes the person's position and friction becomes less of a factor.