X-ray emission from BL-Lacertae objects. II. The nature of Markarian 421