Ah I see. When I run adguard on a mac and enable system wide protection, I think it registers itself as a trusted certificate authority and works similar to the “man-in-the-middle” component that you mentioned. This is just my assumption based on the fact that on https websites, if I click the padlock, the certificate info says “Adguard CA”. It also has an explicit option for a deep packet analysis which explicitly states that it can provide better protection by inspecting https traffic so I am guessing that in theory it’s possible.
Yes. This works because AdGuard is installed on your Mac and adds itself to the trusted authorities there. Basically computers with adguard installed will trust the certificate while computers without AdGuard installed will not trust it.
Some companies do something similar (like another commenter here mentioned), where they install their own certificate on all work provided devices, allowing them to man-in-the-middle all connections. Personal devices without the company certificate installed will then just show the certificate error.