Type Ia supernovae ( are used to determine the distance-redshift relation and build the Hubble diagram. Neglecting their host-galaxy peculiar velocities (PVs) may bias the measurement of cosmological parameters. The smaller the redshift, the larger the effect is. We used realistic simulations of observed by the Zwicky Transient Facility (ZTF) to investigate the effect of different methods of taking PVs into account. We studied the impact of neglecting galaxy PVs and their correlations in an analysis of the Hubble diagram. We find that it is necessary to use the PV full covariance matrix computed from the velocity power spectrum to take the sample variance into account. Considering the results we have obtained using simulations, we determine the PV systematic effects in the context of the ZTF SN Ia DR2 sample. We determine the PV impact on the intercept of the Hubble diagram, $a_B$, which is directly linked to the measurement of $H_0$. We show that not taking into account PVs and their correlations results in a shift in the $H_0$ value of about $1.0$ and a slight underestimation of the $H_0$ error bar.