Electricity can either flow through the wire, or up one leg, through the bird and down the other leg. As the bird is a much worse conductor than the wire, almost all of the electrical current flows through the wire.
However, birds do experience a brief static shock when they land on a wire, because their body acts like a capacitor that gets charged up. But a bird is a very weak capacitor and the shock amounts to less than half a milliamp.