Force the redirect from primary domaine to subfolder domaine if website is visited by British IP

Hi!

I’m trying to find the solution to always force the redirect from primary domaine (example.com) to subfolder domain (example.com/en) if my website is visited by (for instance) British IP.

And backwards, if i try to visit subfolder domain from IP that is different from British, i will be redirected to the primary domain.

I believe that the default settings allow me to visit my primary domain anyway.

Would appreciate any help!