Landlord not giving back deposit

Hello, We were a group of 3 girls who had rented an apartment near our college. The security deposit we paid was ₹100000 in total i.e. ₹33333 each. Agreement has name of all 3 of us. Rent was ₹18000/ month i.e. ₹6000 each. Agreement ended in jul/aug 2020 but due to covid we had gone back to our hometown in March 2020 itself, hoping to resume college some days. So we had left all our stuff in the flat only. But the situation played out differently and we were at our homes only for the next several months the owner said she'll charge only half the rent i.e ₹9000/month (₹3000/month each) from March as we are not staying there and will keep charging the same amount till we come and vacate the flat. It was possible for us to vacate the flat in October only due to covid situation, we did it and handed over the keys on October 10. The owner was supposed to give me back my share of deposit of ₹20000 (33333 was initial amount but 12000₹ was deducted from it as unpaid rent for some previous month's and 1333₹ as cleaning charges), the other 2 girls had also some different unpaid amounts. The landlord is refusing to give back my share of deposit until the other girls have cleared their dues. Even though my side of account is clear with her she is holding back my security deposit amount as collateral since 2 months now and refusing to return it. Is this legal? Can you please guide me through it