How to create a smooth surface onto a rectangle frame?
You could use the bevel modifier to create the rounded edges on the unscaled standard cube.

Add an edge loop Alt-R in the upper part and delete the bottom vertices.

Select the beveled part and scale it along the z-axis S,Z
Note that you shouldn't scale the object to align it to the original model because this would distort the edges. Use select and grab instead.