This seems like something that should have a known answer, but I haven't found it after some time alternating between searching and generating multiple pages of algebra. I'm interested in $k=4$ and $k=6$, but I'll phrase it for general $k$:

Given $k$ identical rectangles of dimension $a \times b$ (let's assume $a \leq b$), what is the smallest square that can contain them if the rectangles do not overlap and can be placed at any orientation (i.e., not necessarily parallel to the square's sides)?