We study phonon-induced pure dephasing in a double-quantum-dot qubit that is embedded in a freestanding slab. The dispersion relations are evaluated to probe the phonon characteristics of the slab. The pure dephasing factor in the off-diagonal elements of the density matrix is calculated. Numerical results demonstrate that time evolution of this factor exhibits a nonmonotonic feature, resulting from the phonon confinement effect. Significant contribution from individual phonon mode is analyzed in detail. We also study effects of temperature and double-dot position on the pure dephasing. In particular, two remarkable oscillations are observed due to phonon van Hove singularities.