Solidworks is excellent for reflective optics, and for prismatic, mainly planar systems. You can simulate Snell’s law either with an equation, or a simple construction using line segments of unit length, and of length equal to the refractive index of the surrounding medium. If you have nothing else, but you understand optics, you might get by with Solidworks. And there are commercial optics addins that have been written using the SolidWorks API.
Commercial tools like Zemax cost a leg (> $13k, and they were changing to subscriptions even before being bought by ANSYS) and have a rather steep learning curve. There are newcomers like COMSOL offering a ray tracing toolbox, haven't tried but they are offering generous free trials and the price seems to be more reasonable.
Edit: maybe the abadonware Beam4 mentioned by another post worth trying.
https://lambdares.com/oslo-edu-download
FRED also has a demo mode
https://photonengr.com/fred-software/demo-request/
That might be enough for simple designs.
Beam Four is also decent and allows you to use most common surface types including gratings.
I'm interested in Optica (for Mathematica) but I don't know anyone that's used it.