The iPhone counts steps using its built-in motion sensors to track your movement throughout the day. It uses the Health app to display your daily step count and provides insights into your activity levels. This feature helps you stay aware of your physical activity and encourages a more active lifestyle.