Mixing GRX crankset with Deore groupset on 2021 Trek Dual Sport 4
It will be fine, as it's just a one-by ring for 11speed. You could also use a sram apex1, a miche graf, or any number of other options.
You will also need the matching bottom bracket for your chosen crank.
Fwiw, most manufacturers spec a cheaper crank, wheels and/or brakes to meet a certain price point, to avoid cheapening the frame or headline components.