Glad that it worked out in the end. It’s a pity that different Android versions and custom ROMs have this setting in different places, I guess this is also making it impossible for the developer to put a direct link to this setting in Heliboard that would work for all users.
May I recommend OSS Document Scanner + Syncthing? Both apps are FOSS and it looks to me like that they might be able to replace what Microsoft Lens does for you with the advantage that you are free of Microsoft software.