It’s not a legal requirement.
HOWEVER, many gyms will not hire a trainer unless said trainer has a certification.
In an ideal world, the educated consumer will ask what certification a trainer holds and what additional training they’ve taken prior to hiring.