Context:
The informant is a Russian-American-Bulgarian woman who spent the first half of her life in Russia. She currently resides in Boston, MA and the interview took place over zoom in which I interviewed her about the Russian folklore that she grew up with and that she feels represents the Russian people and culture.
Dark wizard who was able to separate his mortality from himself and hide it away. Usually it is hidden in a needle, which is located in an egg, which is hidden in a duck, the duck was hidden somewhere else, and so on and so forth. Similar to the Matreshka system. When you wanted to defeat Koshei, you had to find his mortality – his death.
Analysis:
The description of Koshei the Deathless separating his mortality, is one that is very reminiscent of the horcruxes from Harry Potter. I do not know if folklore in other cultures has a similar motif of hiding your mortality in physical objects, but given how prominent a theme death is in all walks of life, it is very likely.
I do not know if JK Rowling intentionally drew from Russian folklore for her books, but I doubt that it was a coincidence. This brings up themes of copyrighted work drawing from folklore, and due to the uncopyrighted nature of folklore, not feeling the need to give credit to or acknowledge what the ideas were inspired by
For another version, read: https://www.ancient-origins.net/myths-legends-europe/slavic-legend-immortality-koschei-deathless-002717