Does the word "commute" apply only to work? [closed]

No, it means especially to work, but not exclusively to work.

Consider https://www.merriam-webster.com/dictionary/commuting :

to travel back and forth regularly (as between a suburb and a city)

It is fairly easy to use the word for other, non-work vocational commutes, such as in the common term commuter school for a college or university that mostly services folks living in an area (rather than students who move to the campus). It would be trickier to use for other trips, but is permissible.

Trip is easier to use. Context can make it clear that it is recurring.