This applies both under Payment of Wages Act (for employees) and under Standing Orders (for employees and trainees) and under Apprentice Regulations. Please remember that they may be employees even if you call them trainees. the amount payable may be a salary / wage even if you call it a stipend.
Training expenses can be deducted only if you disclosed the training cost before, and specified minimum period to work to be eligible for training cost not being recovered from them. Even then, it must be actual training cost paid to an external faculty or institution and not internal costs created or imputed.
Basically, I think your policy is faulty (at best) or exploitive (at worse).
If the matter goes before courts or authorities, it will mostly not stand scrutiny
This is more so if you are terminating them or asking them to leave, not that they are resigning and absconding with out notice.
From India, Mumbai