This can happen if the Maximum Units value for the task is set to a number smaller than the resource capacity. To check and/or update the task's Maximum Units, click the task in the Gantt chart and locate the Max. Unit value in the Task Details Popup.

This Max. Units value defines the maximum number of resource units that can be allocated for the task.