How would you like to activate the timer? Dashboard? Alexa? Physical button press? Other?
One option is to use a dedicated app, like Auto Off or Auto_Off. Both are available in Hubitat Package Manager, at least the last I knew they both were.
Another option would be to use a virtual switch and a rule to turn off "X" minutes after it turns on. This would be fairly flexible and would work by voice command as well as dashboards.
Depending upon the time you need, virtual switches also can turn themselves off at a few predetermined intervals, you could just simply turn that virtual switch on, and it turns itself off. The choices are fairly limited and short, I think the longest you can get is 10 seconds? But that might be fine for some specific cases.