Books
Ser Davos asked the same thing of Melisandre when he was taking her to slay Ser Cortnay Penrose, Renly's Castellan for Storm's End.
“There was no need,” she said. “He was unprotected. But here... this
Storm’s End is an old place. There are spells woven into the stones.
Dark walls that no shadow can pass-ancient, forgotten, yet still in
place.”
“Shadow?” Davos felt his flesh prickling. “A shadow is a thing of
darkness.”
“You are more ignorant than a child, ser knight. There are no shadows
in the dark. Shadows are the servants of light, the children of fire.
The brightest flame casts the darkest shadows.”
ACOK - Davos II
Show
In the show the dialogue went differently but the essence was same:
Davos: Strange that this Lord of Light asks you to work in the shadows.
Melisandre: Shadows cannot live in the dark, Ser Davos. They are servants of light, the children of fire. And the brighter the flame,
the darker they are.
Garden of Bones- S02E04
As to why didn't the Shadow linger around to perform more tasks, there is no information available on that. But my speculation would be that they are a single-use disposable sort of weapon. We see that the Shadow which opened Renly's throat disappeared immediately after his job. And the Shadow which killed Ser Cortnay Penrose vanished as well. Afterwards we see Melisandre asking Ser Davos to make a shadow-baby with her (Since the King's fires were burning low and Melisandre was afraid that another attempt might kill him), Ser Davos refused her.