In a series of three papers, we introduced a novel cluster formation model that describes the formation, growth, and disruption of star clusters in high-resolution cosmological simulations. We tested this model on a Milky Way-sized galaxy and found that various properties of young massive clusters, such as the mass function and formation efficiency, are consistent with observations in the local universe. Interestingly, most massive clusters – globular cluster candidates – are preferentially formed during major merger events. We follow the dynamical evolution of clusters in the galactic tidal field. Due to tidal disruption, the cluster mass function evolves from initial power law to a peaked shape. The surviving clusters at z = 0 show a broad range of metallicity [Fe/H] from -3 to -0.5. A robust prediction of the model is the age–metallicity relation, in which metal-rich clusters are systematically younger than metal-poor clusters by up to 3 Gyr.