You are allowed a bank account while bankrupt. There is nothing illegal about having your wages paid into an account in someone else's name.
However, your friend is pretty unwise to do what she says. Using a debit card could easily result in an overdraft on the account (even if one is not authorised); if the girl didn't (or couldn't) pay it off your friend is legally liable, as the account is in her name.
Far better to help the bankrupt get a basic account in her own name - Co-op Bank are the best for that, & often give an Electron card with the account.