A regular polygon has all sides of the same length and all internal angles the same.
Both conditions are necessary.
For example, a rectangle has all angles the same, but is not generally regular and a rhombus has all sides of the same length, but is not generally regular.
A square is a regular four sided polygon, i.e. a regular quadrilateral.