Depending on your freehub, it may not necessarily line up & change properly without readjusting the rear mech set screws, even if you are using the correct cassette for your shifters. I recently got an Elite Direto which I'm using with a 10-speed Tiagra bike - the bike's own freehub is 11-speed with two spacers for use with smaller cassettes, but the (alleged) 11sp hub on the trainer is different, and requires a different spacer combination and a tweak of the set screws to make it line up with my 10sp cassette.
Fortunately for me, this bike's only used on the turbo, because it would be a proper pain in the ar$e to have to readjust the gears any time I wanted to use the bike outdoors.