The two capital sides started the game on Tuesday night at Madrid's Vallecas stadium and the first-half was marked by defensive errors.
But while Lunin was able to avoid disaster when a poor clearance by defender Kenneth Omeruo was about to cross the goal line, Rayo keeper Alberto could do nothing to stop a ball that deflected off teammate Emiliano Velazquez and into the net to put Leganes ahead 1-0 in the 16th minute, reports Efe news.
Toward the end of the half, Rayo's Bebe tested Lunin with a low shot before seeing the keeper stop him from the penalty spot.
Rayo dominated possession in the second half against a visiting squad content to wait for chances on the counter that turned out to be rare.
(This story has not been edited by Business Standard staff and is auto-generated from a syndicated feed.)