How does one create a neural network where it's parameters are **NOT** leafs?

I want a neural network where the parameters are not leafs. Is that possible?

I’ve tried it but get some issues: How is it possible that I can't create a deep copy although all my parameters are leafs?