https://www.esoui.com/forums/showthread.php?t=9865
Btw: Creating custom quests would be possible but not with something to unlock a custom companion, nor adding it to the game.
Companion settings, menus and stuff is all handled by the server. You cannot even show the companion menus without interacting with them to trigger the server stuff properly first.