The friend is from Ukraine, as their flag (rotated 90 degrees in either direction) can be formed on the grid, preserving the 2:3 ratio of the flag (and the equally-sized stripes). This is the only flag that works, since based on the constraints of the puzzle, the flag must only consist of areas with square borders (ie. no symbols, circles, triangles, stars, etc.) and cannot contain white or black, which greatly reduces the number of valid flags. Additionally, since (I'm pretty sure) it is impossible to form a rectangular region with the S- and Z-tetrominoes, the flag must be made of blue, orange, yellow, and/or purple polygons with sides connected at right angles, leaving only Sweden and Ukraine to fit this description. Sweden's flag is an invalid option, as to "exactly match [its] dimensions", the flag (rotated 90 degrees in either direction) would have to be ten tiles wide, violating the first constraint (the "thicknesses" of each colour in the Swedish flag horizontally are 5, 2, and 9, respectively, which can't be scaled down to integer values).
I don't know if this is appropriate for this site, but consider donating to organizations that support those in Ukraine right now, like Save the Children.