Where are you from? If you are in the US, it may be possible that there is xylazine in your heroin. However, if you are in the US it is also possible that there is very little heroin in your heroin, and other opioids (e.g. fentanyl) alongside xylazine are present as adulterants.
Xylazine is known to be deeply embedded in the US opioid market (mainly in fentanyl, but sometimes in heroin too).
Friedman et al. 2021
Xylazine is known to cause skin ulcers and lesions upon injection. Is it possible that your symptoms match with these (I imagine in a lesser manner)?
Malayala et al. 2022
I am not aware of any method to clean your product to get rid of the xylazine, but nonetheless you can send a sample to Energy Control in Spain for testing and then we can work based on what you have.
I know it may be difficult, but consider smoking instead of injecting until you figure out the reason for your skin lesions. If your heroin is adulterated with xylazine, these lesions will just get worse.