You can easily set the board up from a specific point and play the engine from there.
For example, if you want to learn the French advance with 3...b6, 3...c5 4.c3 Qb6 5.Nf3 Bd7 6.Be2 b5 7.c4, 3...c5 4.c3 Nc6 5.Nf3 Qb6 6.a3 c4, and 3...c5 4.c3 Nc6 5.Nf3 Qb6 6.a3 Nh6, simply use position setup and set up each position and have the computer play Black, yourself White, from that position.
I am trying to learn 1. e4 and want my engine to play the moves from my lines during game play. I m aware that you can build an opening book (polyglot), but I am not sure if the engine will play those lines. I have about 20 lines to start with.
Ideal way - Plug my lines in one pgn (White and Black). Create a bin file and use that with my engine.