Do you mean the CSS width property?
Check out my CSS course where I get into CSS layout, I go into detail how the horizontal space an element takes is affected by margins, padding and borders.
That said, with CSS Grid and flexbox, this becomes a non issue but for older browsers, you still need to understand this. Makes sense?