You have to accept certain problems when you shoot into the sun. One is that the sun will always be blown out unless you hide it. Two, you need to make exposure decisions on what's important. No camera can hold the dynamic range of a scene where the sun is included. So you have to decide where to keep detail and you need to understand exposure to get what you want predictably and consistently. Three, there will be flare unless you shade the lens.
If the sun is not in the picture, it opens up new opportunities to include back light and rim light if you understand how that light works and how to expose properly. Hiding the sun also helps reduce contrast and make for interesting compositions. In your picture, the only way you could have held detail in the sky and foreground is if you would have added a large light, or maybe a silver reflector, to fill in the foreground. Or you could do HDR, where multiple exposures are combined. Without knowing the exact image or effect you wanted to achieve, it's difficult to provide you specific advice.