You would have to use the rules API to create the rule and add it to your SmartThings account. That’s why people are referring to “rules“ instead of “routines. Routines are created through the SmartThings app. Rules have to be created on a computer and uploaded to your account.There’s a whole section of the forum discussing that process.
Alternatively, if you’re not a programmer an easier way would be to use the third-party SharpTools rules engine. See the following discussion.