Lg does have problems with passing through audio. All you can expect from it is dolby Digital or dts Core If your TV supports passing through bacause you’re using optical output
Never heard 5.1 from YouTube. Can you share some link with dd audio from YouTube?
In Kodi / Settings / System / Audio:
Set “Audio output device” to AugeSound HDMI.
Set “Number of channels” to 2.0
Set “Audio Passthrough” to Allow passthrough
Enable all audio formats your AV receiver supports.