Check out Write → Notation options → Accidentals.
Note that you’ll have to select all the flows in the left hand panel if you want the changes to affect the whole project. You can save your preferences as default if you wish to keep them for all new projects.
To change accidentals on an individual basis, have a look in the properties panel
Be careful with “hide accidentals” in the properties panel. If you rewrite the music and the accidental becomes required and not cautionary, it will stay hidden! Dorico will play the “right” note taking account of the hidden accidental, but a human performer probably wont…
Finding the right global option for cautionary accidentals avoids that elephant trap, of course.