There are two reasons why water doesn't clean well by itself. Both
of these reasons have to do with water's high polarity.
The strong surface tension of water prevents it from getting
into small spaces.
Most dirt is non-polar so it doesn't dissolve well in polar water.
Sodium sterate is a common soap which solves both of the problems described
above.
Show molecular suface with electrostatic potential
Notice that one end is polar and the other end is non-polar.
This make sodium sterate a kind of schizophrenic molecule. It can dissolve
in both polar and non-polar substances.
When soaps are dissolved in water the molecules arrange themselves into
groups called micels. The non-polar ends will congregate together while the
polar ends will interact with the water. Because dirt is mostly non-polar
the dirt gets dissolved into the center of the micelle.