Instantiate UI object in Unity and doesn't show in the screen?

I have a code like this in Unity (CSharp):

public GameObject button;
public GameObject panel;

void Start () {
button.transform.SetParent (panel.transform);
Sprite shape = Resources.Load(“Logo”);
var img = button.transform.GetComponent(“Image”) as Image;
img.sprite = shape;
img.color = new Color (50, 50, 50, 50);
}

Now, this is how my scene looks before Play:

The button in the left side is the one i will try to instantiate in my code and “Albumes” is the Panel.

Then, when I press the Play Button I get this:

I can see in the inspector that the sprite was successfuly loaded

Can somebody give me any clue about this behavior?

Hard to say from your screenshots. What do the transform values say for the button in both?
This may be what you need:

button.transform.SetParent (panel.transform, true); // Keep world position