It was ambiguous; the writeup for Alfred Timothy in the Black Box says it appears that he's getting his spells from the 'wolf god', rather than Ravenloft itself. (Yagno Petrovna, by contrast, was always clearly getting his spells from Ravenloft/the Dark Powers.)
It is vague and somewhat contradictory.
"Priests fit one of two general descriptions: those who worship a pantheon of gods but no god in particular, and those devoted to a specific deity. Druids belong to the second group; they worship a deity of the forest or nature. No matter which group they belong to,
priests obtain spells through prayer. A deity answers those prayers and grants the spells. Unfortunately,
in Ravenloft the lines of communication between priests and deities are somewhat flawed. The results of any spell may be altered. Check the chapter on magic for specifics."
The only two statted NPC priests in the Realms of Terror Boxed Set are Yagno and Alfred, although others are mentioned like Arijani the high priest of Kali and various unnamed and unstatted priests.
"Yagno is an 11th level priest of Zhakata and a master of the dagger. (Zhakata is not real;
Ravenloft grants Petrovna his spells.) His spheres are all, charm, combat, elemental, healing (reversed only), and summoning."
"Timothy's spells undergo the changes noted in Chapter IX. It appears, therefore, that the wolf god grants his spells, not the dark powers of Ravenloft. (If Ravenloft granted his spells, they probably would work without penalty.)"
This last entry seems less than helpful to me, there is nothing in Yagno's entry specifying whether his spells work like all priest spells in Ravenloft or work "without penalty" as an exception to the spell casting in Ravenloft alterations.
The entry on spells seems to indicate that the spell alterations are just how spells work in Ravenloft. I would expect creatures Yagno summons to be bound by the Ravenloft spell changes not letting summoned creatures escape when the duration is over.
"Ravenloft is insulated from outside forces, particularly the forces of good. Some spells have new effects as a result, especially those involving divination, summoning, and necromancy. This chapter describes changes to familiar spells in Ravenloft. At the end of the chapter, you'll find several new spells, too."
"Spells from the sphere of summoning may be unusually limited. Ravenloft is severed from normal realms, and a given domain may not offer a full complement of animals and monsters.
Priests cannot summon an animal that doesn't live in the domain they're visiting. Check the chapter explaining mapped areas. If the domain's description does not state otherwise, you can assume that all normal animals are available."
"The priest spells listed below work differently in Ravenloft."
This ambiguity continues forward in the line.
Later on in Darklords Ankhtepot is a former priest of Ra who after being cursed for turning his back on the gods still has those spellcasting powers but it is not specified where he gets them from now.