Immediately after the Democrats shock loss in 2016, they were all saying: y’know, the one consolation of losing the presidency is that during the midterms in two years (from the presidential election) the Democrats will virtually surely pickup seats in Congress, as they’re the party out of the White House and that party almost always wins seats.
They essentially knew it even before Trump and the current Congress were sworn into office since it has been the case in almost every midterm since at least WWII.