I'm aware this is a metaphor, not speaking to actual birds. As a metaphor I'll admit it falls flat because you... flatten the bird's head with a fucking rock.
But people in the comments are addressing it literally so I'd like to address that.
Coming at this as someone who did animal intelligence/ethics as my BSc project - 'suffering ends with death'. It's a bit situational. Generally if I found a dying animal it would depend on which animal it is. A dying swallow might find my presence distressing. Projecting the idea that a bird doesn't want to die alone could lead to this animal, a prey animal, feeling distress more than needed in its final moments.
Be aware, commenters, of anthropomorphising actual wild animals. Do your research if you do want to help them. In some cases expediting their death IS kinder. Believing that you don't get to 'make choices for it' ignores that it didn't choose to be dying.
This applies if an animal is beyond help, I mean. If its death is imminent and painful it is kinder to kill it. Simple as. Choosing to let it suffer because you, a human, don't want to use your rational mind because you think you 'have no right' is wilfully denying our duty to reduce animal suffering.
Nature's brutal. Humans don't have to be.