I want to ask if we take a loan from anybody and if we don't return that money then at the time of our amaal calculation of our life taken by Allah we have to return that money in the form of our namaaz i.e
of 27namaaz with jamaat for 1 paise each

No doubt if qarza was taken it must be given back.if it is not paid back aamal will be spoiled and that person will be punished on the day of judgment for not paying the qarz.but mentioned riwayat is not in my knowledge
If one is unable to pay in time can make request and get some more time.if he is unable to pay then seek forgiveness