For the Japanese, praying for the peaceful passing of a malevolent soul is part of the process. We call it exorcism, but I feel like it's a poor word choice because it's a bit more involved for the Japanese. For them, it's more like cutting whatever ties that soul to this world - either by resolving the cause or impetus of whatever grudge that they may hold, or simply just getting them to let it go - so that they can pass on to the next world. And in order to do so, they have a long ceremony that is performed by a Shinto priest.
Burying the carcasses and praying is just a quick and dirty version, but it's probably very much more fitting of lesser malevolent spirits like those wolves. But that Sword Wolf, though... I have a feeling we're gonna see the reason for it being there pretty soon. And as long as whatever that thing is gets resolved, then all should be well.
Other places we see this:
The first few minutes of Princess Mononoke, where the wise woman of the Imishi Tribe prays to the fallen boar god, promising a burial mound and funerary rights.
Also in the anime series, Katanagatari, where the protagonist's older sister had just lain waste to a ninja cell. Even though they were her enemies, she buries all of them, leaving grave markers on each of their mounds, and performs a small ceremony with incense.