If teachers have more than 6 periods per day, they can teach only 3 periods consecutive.

You can use advanced relation nb 84 - "Max consecutive periods (extended)".

In first parameter set a maximum of 3 consecutive lessons and a threshold of 6 lessons per day, the program will enforce this limit only on days when a teacher has more than 6 lessons scheduled. Days with fewer lessons will be ignored for this constraint.