Your baby is much more aware of things around and within him. All this while he has been consciously or unconsciously learning things and gathering the confidence to implement. Knowing about his bowel movement is one of the major development that takes place at this age.
What you need to know
Your baby is much aware of himself and should be able to indicate when he needs the washroom. However, he may not be able to speak in complete sentence yet. So, you need to look for indications.
Create words that both of you understand and can express through, till your baby is speaking loud and clear. These code words and indications are good enough to understand your baby's feelings. However, make sure that you do not yell at your child regarding this. This may instill fear in him and may turn things otherwise.