A flippant answer would be, why does it matter?
For someone used to working body parts individually like a body builder, we would say that squats should not be your primary movement for posterior leg development. But are those muscles activated during a property execute back squat? Absolutely.
Your hamstrings, the group of muscles on the back side of your thigh, attach at the sit bones of the hip (ischial tuberosity) to your femur, tibia, and fibula. They are vital to functional movement (like walking and standing up) and somewhat unique in that they cross two joints, the hip and the knee.
Those muscles are responsible for knee flexion (heel to butt) and hip extension (straightening up). In the squat, gravity is doing the majority of the work flexing your knee and your hips are flexing as well (smaller angle between your torso and thigh). But the hamstrings are active throughout, stabilizing the knee. As you stand, this stabilization continues and the hamstrings shorten in the portion of the squat where that torso-thigh angle opens back up and you stand. The heavier the squat, the greater the activation.
Conventional wisdom says that your hamstrings are most active in a properly executed low bar back squat, but not as much with a high-bar back squat or front squat with a more vertical. Testing shows that the hamstrings are active in all types of squats – the heavier the squat, the greater the activation. (Journal of Strength and Conditioning Research: April 2012 – Volume 26 – Issue 4 – p 1169–1178)
But if you want to isolate the training stimulus of hamstrings, then exercises such as the stiff-legged deadlift, leg curl, or GH raise are superior movements. (Jensen, RL. “Hamstring electromyographic response of the back squat at different knee angles during eccentric and concentric phases.” In Proceedings of the XVIII International Symposium of Biomechanics in Sports, Vol. 1 (Hong, Y &Johns, DP, editors) 2000;158-161)
This is similar for the calves. In a proper squat, they are isometrically active to keep you from falling over. But unlike jumping, sprinting or calf raises, there isn’t any foot flexion (unless you pitch forward!), so those exercises are superior for calf development. But your feet and calves are important stabilizers during the squat; they are active.
If your goals include oiling up and posing in a Speedo, then squats can’t be the only thing you use for your calves and hammies. But to make sure that your prime movers for athletic power are as strong as they can be, they are irreplaceable.