I don't have this game, I can't test if it works correctly.
I suggest the open source tool Advanced Genie Editor 2019. (github repository).
On the linked website it says:
Advanced Genie Editor
for Age of Empires, Rise of Rome, Age of Kings, The Conquerors (including HD), Star Wars Galactic Battlegrounds and Clone Campaigns.
This is a program to edit genie file data (DAT and DLL). You can edit properties of units, civilizations, technologies, graphics, terrain, sounds, player colors and some other things.
It should work with 2018 Final edition If you select this version from the drop-down list of the Genie version when opening files, as shown below:
Advanced dialog Genie Editor "Open files …"
The application has support for editing technology trees, among other things:
Main window of the Advanced Genie Editor, Technology Trees tab, no open file.
That should allow you to eliminate access to particular units for given civilizations. Remember to make a backup of your dat files.
I found this tool linked from aoe.heavengames.com. I didn't see any real alternatives while searching.
I tried the tool in a friend's game copy. I had to put the path to the dat file manually. There is no language.dll file, disable it when you open it. There is an option to copy a civilization (in the "Civilizations" tab) and to disable units to particular civilizations (in the "Units" tab). However, the edition of the technology tree for a particular civilization was not available (there was no tab "Technological trees").