This might help:
How to Get Started Creating Complex Rules in SmartThings (2017) (SmartThings Classic)
As far as specifically your question about sunset/sunrise, yes, that’s part of the official features.
Rules are called “ automations“ in the official features. One of the popular unofficial communitybuilt rules engines, webcore, calls rules “pistons.“