Blood in sputum is caused by few things and the most common ones are bronchitis, bronchiectasis, and lung cancer.
Both, bronchitis and bronchiectasis, are accompanied with severe coughing.
Lung infection can give blood in sputum, too, coughing could be present or not, but it is accompanied with fever, and chest pains.
It is very important to get additional examinations like bronchoscopy (to check for cancer that raises from airways) and lung Ct, since it is a golden standard for diagnosing lung cancer.
Best wishes!