The coherent interaction of extremely short light pulses with a resonant medium can result in the formation of population difference gratings. Such gratings have been created by pulses that are π/2 or smaller. This paper demonstrates that a microcavity with Bragg-like mirrors can be formed by colliding two single-cycle attosecond self-induced transparency pulses in the center of a two-level medium. The parameters of this structure can be quickly adjusted by increasing the number of collisions, which showcases the ability to control the dynamic properties of the medium on a sub-cycle time scale by using attosecond pulses.