How to cast shadows of instances with level of detail?

Just for completeness:

In my case I disabled the LOD_0 mesh instead of just making it invisible.

lod1.parent = lod0
lod0.addLODLevel(50, lod1)

//the original object should not be visible
//my approach was wrong
lod0.setEnabled(false)
//this is the correct way, as stated in documentation
lod0.isVisible = false

//afterwards instancing with shadows should work properly
instance = lod0.createInstance("")