iMac to A/V digital connection and playback
I have a 2018 iMac running O/S Mojave 10.14.5. I am trying to get my iMac connected to my Marantz A/V amp for playback of Apple Music, etc. Online suggestions are confusing - example: Toslink cable out of headphone jack (supposed to go in far enough to connect to something to change to optical out) then to optical in on the back of my A/V. I bought that type of cable https://www.amazon.com/gp/product/B00T8HWV62/ref=ppx_yo_dt_b_asin_title_o08_s00?ie=UTF8&psc=1
and then set up my A/V amp to recognize the input. But the iMac output through the headphone jack has not changed automatically as some online have suggested would happen, nor can I find any settings in System Preferences to manually make changes. Looking back through previous posts were not at all helpful and they were 2012 or 2013 posts. It's 2019, I need up to date help. Has anybody been though this recently that can offer me some help on this.
iMac 27" 5K, macOS 10.14