Constructions of synthetic lattices in modulated ring resonators attract growing attention to interesting physics beyond the geometric dimensionality, where complicated connectivities between resonant frequency modes are explored in many theoretical proposals. We implement experimental demonstration of generating a stub lattice along the frequency axis of light, in two coupled ring resonators of different lengths, with the longer one dynamically modulated. Such a synthetic photonic structure intrinsically exhibits the physics of flat band. We show that the time-resolved band structure read-out from the drop-port output of the excited ring is the intensity projection of the band structure onto a specific resonant mode in the synthetic momentum space, where gapped flat band, mode localization effect, and flat-to-nonflat band transition are observed in experiments and verified by simulations. This work provides evidence for constructing a synthetic stub lattice using two different rings, which, hence, makes a solid step toward experimentally constructing complicated lattices in multiple rings associated with synthetic frequency dimensions.