Non transfer of stamp duty & registration from original flat to realloted flat by builder

I had bought a flat from the builder and as part of the process had registered the flat paying the stamp duty and applicable registration charges as availed loan on the said flat from the bank. Post the complete payment the builder could not hand over the flat due to an existing mortgage of the bank taken by the builder, fact hidden from me. After knowing and constant follow up the builder realloted another flat in the same project. Now the issue is the builder who was supposed to transfer the original paid stamp duty & registration charges from the original booked flat never got done due to the issues faced by him due to which the realloted flat though paper work and possession documents were transferred in my name. I presently occupy the realloted flat with clear tittle and hold tittle to the original flat booked which was sold fraudulently to another person by the builder. The said flat is still under bank mortage for the loan availed by me on it. How do I resolve the issue by getting the transfer of my original registration to the present flat. The builder over the years had promised to get it registered but till date he has not been able to do it due numerous issues faced by him besides multiple cases being filed against him. Need advice to resolve the issue.