Self-interaction of optical beams under resonance absorption conditions