Although some grammarians consider it to belong to the category of MOOD, modality actually stands on its own, particularly in the English language where it is primarily marked by the system of MODAL VERBS.
If we compare the following sentences:
1. It is raining. (INDICATIVE; marks the statement for the factuality of action/state/event described by it)
2. It may be raining outside. (MODALITY)
we can define MODALITY as the way in which the meaning of a proposition is modified so as to reflect the speaker's/subject's attitude towards the likelihood of the proposition content being or becoming true.
According to their meanings, the modal verbs are divided into three categories:
1. EPICTEMIC modals are those that express possibility, necessity and prediction.
2. DEONTIC modals are used to impose obligation, give permission and again make a prediction (of another kind, which will be explained further on).
3. DYNAMIC which refer to human's possessing certain abilities.
This category is not modal in the strictest sense of the word since it does not reflect an attitude towards the content of the statement.
Let's compare the following predictions:
1. It will be raining outside.
2. I will do as I please.
The first statement expresses a prediction that cannot be controlled by the speaker in any way, whereas in the latter the speaker has the control over the statement marked by the verb. Uncontrollable predictions fall into the EPISTEMIC category of modal meaning and the controllable ones are DEONTIC. For that reason epistemic modality is called extrinsic and deontic modality is called intrinsic.
English modals have developed a high semantic potential, for example, CAN expresses possibility, permission, and ability. Although they are extremely context sensitive, some of them overlap in meaning: You should see a doctor : You ought to see...