Though this is a complex question and needs a lot of explanation there could be a simple mechanism to understand stone formation and understand ways by which stones form in the urinary tract:
In a container with water if you add some more salt, it dissolves. When you add more and more salt, a stage comes when the salt is no longer able to dissolve. The reason for this is that the solution in the container is supersaturated with the salt. So above this point any further salt added to this saturated solution will start precipitating.
This exactly is the mechanism by which stones form, except the container is kidneys and the solution is urine and the chemical composition of the salt is different.
Another reason for stone formation is : First a negatively or positively charged crystal is formed, which keeps attracting opposite charged crystals as a result it grows in size and then a large number of such grown - up crystals has to aggregate to each other before it becomes large. This could be controlled or avoided if kidneys remain flushed by drinking enough water.
But nature has its own protective mechanisms to prevent stone formation. There are certain substances in urine which control the growth and aggregation of crystals which are responsible for stone formation. These substances in urine (that most of us have) do not let stone formation, As stone forming substances are kept in a dissolved state in our urine.
