Why is the main landing gear of the Cessna Caravan placed so far forward?
You're right, placing the gear more aft would make ground handling much easier and not affect flight stability. But it would make taking off harder.

When the aircraft has accelerated to a speed just below lift-off speed, the wing's angle of attack is too low to create enough lift when that speed is reached, so the pilot will lift the nose while the main gear is still on the ground. This maneuver is called "rotation", and the speed at which the pilot pulls the stick or yoke back to lift up the nose is called rotation speed. By the time the aircraft has the right angle of attack, the lift-off speed is reached and the aircraft takes off.

If the gear is further aft, the downforce on the elevator needed to push the nose up needs to be bigger, and more drag is created during rotation. If the gear is still further aft, the maximum possible downforce at that speed would not be sufficient to get the nose up, and rotation must be delayed. The acceleration up to rotation speed is done with horizontal ground attitude because then the wing creates less lift and also less drag during the take-off run. Therefore, the pilot has to get the nose up to get the plane into the air, or he would need to accelerate to a much higher speed, at which the airplane flies even with its ground attitude. This all helps to minimize the airfield requirements.

To strike the right compromise between ground handling and elevator downforce during rotation, it is recommended to position the main gear along a line from the center of gravity down to the ground which is slanted 10°-15° back. The drawing below shows limits between 6° and 20°, but this is quite a wide range. Details depend on the desired angle of attack at liftoff and the maximum range of the center of gravity.



Side view of the recommended tricycle gear layout (Picture source).