There is no LAW that requires an employer to provide a 401k plan.
There is no LAW that makes it mandatory for an employee to participate in a 401k plan if the employer chooses to provide one.
However, it is possible, and if this is the case it is legal, that your employer has a plan under which everyone is automatically enrolled unless they actively take steps to decline coverage. If that is the case, then nothing you can do will get back what has already been contributed as long as you are employed by this employer, and that is Federal law. Depending on the plan, you may or may not be able to drop participation now; you will have to read the plan document to see when and under what circumstances you can drop.
You may not think it necessary now, but I promise you that if you do not participate, when you are my age you will fervently wish that you had. If you have the opportunity to participate at 24, it is criminally stupid to pass up the opportunity.