I am not defending Tannu or even AbhiGya story here because as a story or quality art all of this rates very low in my head. But given the commercial appeal of the soap and it's audience, Tannu/Leena is more than enough to maintain the show as a villain. Leena has a lot of popularity on social media be it the people who love her for her looks or whatever or the people who hate her for being Tannu!
Yes the script protects Tannu but the script also develops a lot of unnecessary issues for Pragya to keep her showing in trouble and to gain sympathy from audience. There have been a 1000 incidents where Pragya could make her life easy by talking truth but she won't. Likewise there are 1000 loopholes where Tannu should be exposed but she won't get exposed. And like Cerealgirl said, Tannu and villains are used to gain sympathy for Pragya by creating trouble for her. So to me, Tannu or such characters are essential for this soap just like Pragya and of course both characters are sloppy if you ask me.