How do I to defend myself against this? In mid/late game it isn't a problem, but early game is horrible! I don't know what I can do! Potions and healing skills are weak against this too. My main champions are Malzahar and Xin Zhao, but I want a more generic solution, that works with any champion. Thank you!
My personal opinion is that you can't and you actually don't really need to counter ignite.
I mean you could consider cleanse to get rid of the healing debuff so when you get ignited you can just drink a potion and get the full healing it offers. But unless you're facing a CC heavy team having cleanse in mid is just not worth it. It's better if you get an ignite as well (and a flash ofc).
What you wanna do is be careful not to get yourself in a position to die from an ignite. Cause if you do there's not really much you can do. Especially early game. Not many items you can buy to counter it since its early. Like you said healing spells don't do much.
Damage absorbing shields should do you more good there. Like barrier (not worth it imo, much like cleanse) or skill shields like lux's W etc.
All in all ignite is a strong spell and early game the only thing that can save you is awareness of danger and backing out soon enough.
In addition to Panagiotis' insightful answer, you can often use your own intuition to your advantage. You need to know the limits of your own champion as well as the limits of the enemy champion. You should always know what champions on the other team have ignite before the match begins. The best rule of thumb is to assume their ignite is up at all times. Of course, good players will let their teams know when their lane opponents use summoners (i.e. flash is down, so the next gank is easier).
Ignite doesn't really do much damage. It's meant to prevent healing and finish off weak opponents (in the early game especially). If you're losing to ignite, it's already a pretty close fight. Chances are you chose a bad engage. Perhaps you initiated a fight as Malzahar when your ignite was down, and the enemy's ignite was up.