When you are entering the text, or editing the cell later, use <ALT><ENTER> to create the new lines inside the cell

https://exceljet.net/keyboard-shortcuts/start-a-new-line-in-the-same-cell
Or you can use something like this tool
@Excel Formula Beautifierhttp://excelformulabeautifier.com/?numberOfSpaces=3
Parses Excel formulas with indentation ie: =IF(SUM( IF(FOO = BAR, 10, 0), 10 ) = 20 , “FOO”, “BAR”)
is converted to
=IF(
SUM(
IF(
FOO = BAR,
10,
0
),
10
) = 20,
“FOO”,
“BAR”
)
You can copy the spaced out formula back in to Excel in the formula bar (not the cell!) and it will maintain the spacing.
Enlarging the Formula Barhttp://excelribbon.tips.net/T011705_Enlarging_the_Formula_Bar.html****The Formula bar is used to display the formula that appears in a cell. You may want to modify how the Formula bar is displayed. Your modification options are limited, as discussed in this tip.
Formula bar in Excel: show, hide, expand or collapse
2016 01 21 Svetlana Cheusheva
https://www.ablebits.com/office-addins-blog/2016/01/21/formula-bar-excel/
In this short tutorial, you will learn what the Excel formula bar is, how to restore a missing formula bar in different versions of Excel, and how to expand the formula bar so that a long formula can fit into it entirely.
. * What is a formula bar in Excel?
. * How to show formula bar in Excel
. * How to hide formula bar in Excel
. * How to expand and collapse formula bar