Is not what you think
When we think of endurance, we usually think of long things, long rides, long efforts on the track, long runs (urgh!) etc. That's part of it, sure. In the context of sprint training, endurance is two things - the ability to produce power over the duration of our races (short times, not a lot of endurance required and it's very specific) AND, importantly, repeatability.
It's not enough to be able to ride a flying 200, you have to be able to repeat the effort, over and over.
So how do we train for that? In the gym? Yes, you can, we do multiple sets, anyone who'se trained with me in the 'Haus, knows we do 3x3 and 5x5 etc rep ranges, why? The intensity comes from the first couple of sets, the last set is strength endurance, in a useful context.
On the track? Repeating efforts, not making them longer.
Rant ends here!