I think you need to change the
.Top
value before adding the picturebox in
this.panel1.Controls.Add(p);
You could do this by adding all heights into a variable, e.g.
int totalHeight
and using that for the .Top value:
int totalHeight = 0;
foreach (PictureBox p in pictureBoxList)
{
p.Top = totalHeight;
this.panel1.Controls.Add(p);
totalHeight += p.Height;
}