There are basically two reasons.
Reason 1 - A Problem with the Neighbours
When the Third Crusade was launched there had to be agreements as to who would run England and France whilst their kings were away in the Holy Land. There was also an agreement that, since Louis Philip of France and Richard of England liked going to war with one another, the two kings would travel together and act as partners. This was doomed from the start because Richard technically held Normandy as a vassal of the French king, Philip believed that he was in charge and Richard ought to act as a deputy rather than an equal and Richard wanted to prove that he was the better warrior.
So when Philip declared that he was going home after the Siege of Acre finished in 1191, Richard basically had a time limit. Philip was pretty much certain to launch an invasion of Richard's French lands the moment he got home, so Richard had to wrap up the crusade as quickly as possible so that Philip could not effectively capitalise on Richard's absence. There was also the problem of Richard's little brother John, who had ignored previous agreements about who should be running England and had forged an alliance with Philip to take the throne. In other words, Richard needed to get home ASAP. So when Saladin sent envoys to Richard asking to make a peace deal, Richard leapt at the chance. His men were less enthusiastic about going home without taking Jerusalem to the extent that they openly made preparations to advance on the city in direct defiance of Richard's orders. The second time Richard assessed the possibility of taking Jerusalem by marching up the road from Jaffa, he did it to prevent a mutiny. Eventually though, they realised that matters at home could not wait. A short truce allowed Richard to go home, deal with Philip and John, then come back with a fresh army to hopefully take Jerusalem. That was the plan, as Richard made very clear to Saladin's envoys, but Richard died fighting Philip in 1199.
Reason 2 - Geopolitics
The reason Richard's men were keen to attack Jerusalem, besides the obvious spiritual and material glory that might be gained in doing so, was that they thought they could win. They were probably right about this - Richard's army outnumbered the garrison considerably, and Saladin's army had already been taken care of. Richard probably could have taken Jerusalem if he wanted to (though Richard himself did not believe this). The problem was the aftermath. In the short term, there is no way he had the numbers to take on a new relief army if Saladin managed to put one together. In the long term, Jerusalem would have had to exist as a kind of peninsular stretching out from the more secure coastline. The map would have been the cohesive stretch of coastal land, then a line jutting out to Jerusalem. Realistically, were Jerusalem to be reconquered by the Franks, it would be completely undefendable. The only safe route from the secure coastline and Jerusalem was the road from Jaffa and a couple of dubious mountain passes guarded by castles. To keep Jerusalem, those castles would also have to be taken, and other forts built to protect that precious road.
Now keep in mind that sieges could seriously drag on, often for months. The Siege of Acre that began the Third Crusade lasted for almost two full years, though that was a bit exceptional. Richard had neither the time nor resources to siege multiple castles and build even more. They were struggling to build just one - Ascalon - and the treaty he negotiated with Saladin stipulated that it be dismantled. Richard reasoned that there was no point in taking Jerusalem if they were going to lose it again the second he left for home. Saladin's field army may have been defeated, but that didn't mean he couldn't raise another one very quickly and come back.