Monte Carlo simulator of realistic X-ray beam for diagnostic applications