It can and will help you, but it certainly isn't necessary to do either of these movements.
During a handstand, you use your fingers and core to stabilize, during a deadlift you strengthen your core a whole bunch, so that will help you to keep your handstand nice and straight. Once you can do a proper handstand, you can move into handstand push-ups. You might want to add in other shoulder exercises like shoulder press to get a bit more strength in the push movement.
As for muscle-ups, it will help you a bit, in the way that you train overall strength of the body with a deadlift, but I'd say there are a lot better movements to train for a muscle-up than the deadlift, it won't contribute as much as doing dips, pull-up variations and negative muscle-ups.
By pull-up variations I mean not only different grips, but also train for explosive pull-ups, do weighted pull-ups, do negative pull-ups. All these things will help you master the bottom part of the muscle-up.
The top part is basically a straight bar dip, so training dips with help you with that. The negative muscle-ups will help you get used to the transition from the dip to the pull-up, try to do this as controlled as possible for mind-muscle connection.
Please don't do a crossfit muscle-up by the way, that's just plain wrong and will only hurt you in the long run.