The coherent control of a two-level system is among the most essential challenges in modern quantum optics. Understanding its fundamental limitations is crucial, also for the realization of next generation quantum devices. The quantum coherence of a two-level system is fragile in particular, when the two levels are connected via an optical transition, which, at the same time, enables the manipulation of the system. When such quantum emitters are located in solids the coherence suffers from the interaction of the optical transition with the solid state environment, which requires the sample to be cooled to temperatures of a few Kelvin or below. Here, we use a mechanically isolated quantum emitter in hexagonal boron nitride to explore the individual mechanisms which affect the coherence of an optical transition under resonant drive. We operate the system at the threshold where the mechanical isolation collapses in order to study the onset and temperature-dependence of dephasing and independently of spectral diffusion. The insights on the underlying physical decoherence mechanisms reveal a limit in temperature until which coherent driving of the system is possible. This study enables to increase the operation temperature of hBN-based quantum devices, therefore reducing the need for cryogenic cooling.