Substitutes Mohammed Fuseini and Kevin Rodriguez scored in the first 10 minutes of extra time after the two sides were level at 1-1 after 90 minutes.
Union took the lead in the 74th minute through Argentine defender Kevin Mac Allister after they had dominated proceedings.
Earlier, they had a glancing header into the net from a free kick by English-born captain Christian Burgess ruled out for offside following a lengthy VAR review.
Anderlecht, whose supporters halted proceedings during the match with the smoke from their pyrotechnics making it hard for the players to see, equalised in the 80th minute from a set piece, finished off by Mihajlo Cvetkovic.

