I second the tape recorder, but since getting cassettes and keeping them organized is a pain, and it is 2021 after all, the way I would go is a
Zoom H2n ($170)
I have the older H2 and it is about as simple as it gets. You can record anywhere and the sound is decent.
As noted by @equill , there is nothing wrong with the voice recorder on any Android or iPhone. I use it often when I wake up with a melody in my head and have too busy a schedule to go flying down to the studio. I hum a few bars and listen again later. Some of my best musical ideas hit me when I am in a sleep haze and usually forgotten by the time I get vertical.