It seems increasingly clear that the factors that govern what kind of a planet emerges where in a given stellar system are numerous and not always well understood. Beyond the snowline, planets draw themselves together from the ice and other volatiles available in these cold regions, so that we wind up with low-density gas or ice-giants in the outer parts of a stellar system. Sometimes. Rocky worlds are made of silicates and iron, elements that, unlike ice, can withstand the much warmer temperatures inside the snowline. But consider:

https://www.centauri-dreams.org/2019/02/20/kepler-107-collision-of-worlds/