The A Lyga side was made to work hard for the win after the visitors drew in the first blood courtesy Anicet Abel in the 18th minute.
Knowing the implication of a defeat at home, Valdas Dambrauskas' men clawed back in the 78th minute after Nyuiadzi fired past goalkeeper Renan, finishing off a low pass from Darvydas Sernas.
Mantas Kuklys then netted the winner with four minutes left to play with the Togolese making an assist to complete an incredible turnaround for the Lithuanian champions at the Vilniaus LFF Stadium.
But there was more drama to come as Darvydas Sernas was sent off for Zalgiris after a second caution.
The Green-Whites must avoid defeat when they travel to the Ludogorets Arena in a week's time for the return leg - with the third round ticket the prize.