  Modified gravity theories have the potential of explaining the recent
acceleration of the Universe without resorting to the mysterious concept of
dark energy. In particular, it has been pointed out that matter-geometry
coupling may be responsible for the recent cosmological dynamics of the
Universe, and matter itself may play a more fundamental role in the description
of the gravitational processes that usually assumed. We study the quantum
cosmology of the $f(R,T)$ gravity theory, in which the effective Lagrangian of
the gravitational field is given by an arbitrary function of the Ricci scalar,
and the trace of the matter energy-momentum tensor, respectively. For the
background geometry we adopt the Friedmann--Robertson--Walker metric, and we
assume that matter content of the Universe consists of a perfect fluid. We
obtain the general form of the gravitational Hamiltonian, of the quantum
potential, and of the canonical momenta, respectively. This allows us to
formulate the full Wheeler-de Witt equation describing the quantum properties
of this modified gravity model. As a specific application we consider in detail
the quantum cosmology of the $f(R,T)=F^0(R)+\theta RT$ model, in which $F^0(R)$
is an arbitrary function of the Ricci scalar, and $\theta $ is a function of
the scale factor only. The Hamiltonian form of the equations of motion, and the
Wheeler-de Witt equations are obtained, and a time parameter for the
corresponding dynamical system is identified, which allows to formulate the
Schr\"{o}dinger--Wheeler--de Witt equation for the quantum-mechanical
description of the model under consideration. A perturbative approach for the
study of this equation is developed, and the energy levels of the Universe are
obtained by using a twofold degenerate perturbation approach. A second
quantization approach for the description of quantum time is also proposed, and
briefly discussed.
