Retained earnings is simply accumulated profits. It is the total of profits that have been accumulated over the years for the business. In the image above the retained earnings is the balance at the end of the year.
Retained earnings is shown on the balance sheet under the owner's equity section.
Why is profit and retained earnings not included in the cash flow statement? Simple. Both of these profit items do not represent cash.
Remember that profit is incomes minus expenses. And both incomes and expenses can occur with or without a movement of cash. For example, one has the telephone bill as an expense but you don't pay it before the end of the year. This is known as an accrual item, which basically means something occurring on credit.
The cash flow statement only shows cash items. So profits are not shown here, only flows of cash coming in and cash going out.