That should be OK as long as you never set WAN DNS to the PiHole IP, creating a loop.
You can also install Stubby on the Pi and have Pi-Hole use it to do DoT and DNSSEC. For me it seems to work better than Stubby on the router.
Welcome To SNBForums
SNBForums is a community for anyone who wants to learn about or discuss the latest in wireless routers, network storage and the ins and outs of building and maintaining a small network.
If you'd like to post a question, simply register and have at it!
While you're at it, please check out SmallNetBuilder for product reviews and our famous Router Charts, Ranker and plenty more!