Why do ancient poems have the same number of words per line?
That's not true. There are two sources of ancient poetry, one is the Book of Songs and the other is the Songs of the South. Their word count is different. It was only in the Tang Dynasty that people generally realized the characteristics of Chinese, and created special poems, that is, metrical poems and quatrains, which strictly required the same number of words in each sentence. Later, new poetic styles, such as words and songs, were relaxed, but metrical poems are still loved by people because they reflect the advantages and characteristics of Chinese.