Good how and where? That's a very uncritical take you have here.
I find it is way too complicated with regards to flexbox, grid etc...
Just do a google search for flexible divs side by side. Start with two. Then switch to five. Tell me the solutions that work well.
"flexible divs side by side" sounds like something which can be generated in many ways, From display: inline-block, over float:left, col-columns, flex layout, to a grid based layout. Can what you desire be created in, for example, https://grid.layoutit.com/?
flexible divs side by side is trivial with both flexbox and grids. Far, far, far easier than prior to flexbox.
don't search, ask an llm. Ask it to keep it as simple as possible and have it explain the tags you've forgotten.
My rule of thumbs is: Use flexbox unless it truly is a grid or repeating rows + "I wonder if a flexbox can be used ... ah yes it can." Flexbox is just made for responsive layouts. It is very good.