Squares fitted in regular polygons.
The process I initially follow , is to start with the regular polygon that I want to insert the squares in, draw a loose point in one of the sides and repeat on the other sides (same length). I draw the squares and move the original point until I find the meeting point of the squares. I use GeoGebra to make the drawings.
The triangle, 3-gon
I can't fit 3 squares in a triangle following this process, but still quite interesting geometrically.
Doing a google search I did find out an interesting page with squares fitted in a pentagon : https://erich-friedman.github.io/packing/squinpen/.
This drawing the same as the one inserting 5 squares in the pentagon, I added the decagons(10-gons),as I find it makes it visually more interesting.
In a hexagon the squares meet in the midpoint of the square.
Heptagon,7-gon