People were talking at the tops of their voices V ... loudly

Hi,

[i]On a boat

The top deck was jam-packed, and people were talking at the tops of their voices.[/i]

Is it fine to say “… people were talking loudly” as well?

Thanks again. Bye bye

Yes.
‘speaking at the top of (his) voice’ is an idiom for ‘speaking very loudly’.

Bingo!