Lopetegui was dismissed on Monday after a disastrous start to the season, with Los Blancos losing four and drawing two of their opening 10 games.
Former B team coach Santiago Solari has been installed as caretaker manager replacing Lopetegui, with talks over a permanent successor continuing.
Ex-Chelsea manager Antonio Conte is the frontrunner to take over, with Goal understanding that negotiations with the Italian are underway.
Nevertheless, Solari has named his first squad as manager for the cup encounter, and has chosen to give Modric and Bale a rest.
Melilla play in the Segunda Division B, with Real expected to chalk up a simple victory.
The likes of Karim Benzema, Sergio Ramos and Casemiro have all been included in the squad, as has young Brazilian sensation Vinicius Jr.
The 18-year-old has played just 12 minutes of senior football this season, but could be given 90 minutes against lower-league opposition on Wednesday.