Before 23.10 you can follow the guide on the FSRS github page.
For there to be an option to activate fsrs in the deck options you will need to upgrade to 23.10+, at which point you will no longer need to paste any code since it is integrated into Anki.