Control of the assembly in New Delhi is set to change hands, a feat that eluded the Indian prime minister’s Bharatiya Janata Party for nearly three decades.