In general, door frames should be installed properly to ensure that doors function correctly and provide a proper seal. A door frame being tilted at 5-10 mm (millimeters) is quite significant and may indicate an installation issue or structural problem. Ideally, door frames should be installed plumb (perfectly vertical) and level (perfectly horizontal).
A slight variation of a few millimeters might not cause significant issues, but it's still best to have door frames installed correctly. However, if the tilt is more pronounced or causing problems such as the door not closing properly, sticking, or creating gaps, it should be addressed. In such cases, it would be advisable to consult a professional, such as a carpenter or a contractor, to assess the situation and provide appropriate guidance or corrective measures.