Create a Shadow because of invisible object (eg: invisible ghost casting shaddow)?

New to Blender (along with 3d work and modeling) so sorry if this is a silly idea/question.

Can you cast a shadow of a definded shape (person/character) but have that object/shape transparent ?

The idea: have a person walking around in front of a green screen, chroma key it, make a 3d model of that person, animate the model to walk the same path as the person did, create a background along with a light source have the animated model walk and create the shadows and later add the real person to the screen with the shadows the “invisible animation” created…

I know you can make shadows with premeir pro, divinci, etc… But…

Can you do things like that in blender (or other modeling software) ?

[edit] - added to thread title (eg: invisible ghost casting shaddow)

Came across this thread which shows how to do this with Cycles, is it possible to do with Eevee ?

[EDIT] Yes it is possible with Eevee also, check this link for more info.