A company which manufactures office equipment has been fined after a trainee worker was injured when he was crushed by a metal folding machine.