  We construct the amplitudes of $\pi\eta$ photoproduction taking into account
the effects of the $\pi\eta$ - $K\bar K$ interchannel coupling. The idea of our
model is close to the molecular description of scalar resonances with exception
that apart from the pseudoscalar loops we include also vector mesons in the
intermediate state loops. These amplitudes are used to calculate the $S$-wave
cross sections and mass distributions in the $\pi\eta$ effective mass region
corresponding to the scalar resonances $a_0(980)$ and $a_0(1450)$. The values
we obtained for $a_0(980)$ are comparable with predictions of other models
while the cross section for $a_0(1450)$ is about an order of magnitude larger
than prediction based on the quark model. We show that the amplitudes with
loops containing vector mesons calculated in the on-shell approximation are not
suppressed in contrast to amplitudes containing only pseudoscalar loops. We
estimate the cross sections for the $P$- and $D$- waves in the $\pi\eta$
channel.
