Fair weather cumulus clouds are white because there is a clear path for sunlight to reflect off the cloud and into your eye. Even when there are many of them, they are not vertically developed and photons can still scatter off of them to you.
As cumulus develop into towering cumulus and cumulonimbus they become horizontally widespread and quite high (the tops of severe convection overshoot into the stratosphere and the convection in the tropics can go even higher, owing to a higher tropopause). A developed CB cloud also features an anvil. These clouds are also optically thick, dense with cloudwater, rain, snow and ice.
For a cloud to appear white, photons representing the full visible spectrum must be able to arrive at your eye. For an optically thick cloud of appreciable thickness, transmission isn't an option. Note that both the physical thickness and the density of the cloud will increase its optical thickness. This means that if the cloud size doesn't change but more and bigger rain drops are in the cloud, it will be optically thicker and appear darker. If there isn't a path from the sun to a surface of the cloud you can see, scattering isn't an option. Water emits in the infrared, so emission isn't an option. If visible photons cannot arrive at your eye from the cloud, then the cloud will appear dark. The presence of hydrometeors (rain drops, snow, hail) in a rain cloud will further decrease transmission and darken the cloud.
Putting it together, as that white cumulus grows and becomes tens of thousands of feet tall, it will still appear white if the sun is on your side of the cloud. It will appear darker if the sun is behind the cloud (transmission through the cloud). As the cloud becomes horizontally thick, transmission will decrease, darkening the cloud if you aren't in a position to observe scattering. Once an anvil starts to form, if you are anywhere near the storm you are likely in shadow and there probably isn't a path for scattering sun->cloud->eye.
In the picture you posted it appears the sun is behind the storm. You can see the anvil in the upper left part of the image is bright white on its edge where you can see scattering from the sun. As you see the anvil toward the storm it darkens because now you are seeing photons transmitted through the anvil, and less are making it to your eye. The updraft is colored similarly, with some light areas with scattering and the bulk of the surface quite dark due to no scattering and low transmission. Under the storm you see some bright clouds via scattering from the sun. You can see this spectrum doesn't appear quite white, a consequence of different wavelengths scattering differently (and this effect can give rise to the green aura people associate with hail, which is really just related to having tall storms causing long path lengths and multiple scattering necessary for photons to reach your eye).