MacBook Pro 13" 2015 A1502 recording vinyls through headphone jack
Record players typically needed a RIAA amplifier in order to get the same electrical signal levels as most other devices like tape recorders or CD players.  These were typically built into the amplifiers.

Today you need this separately.  I have had good experience with a Behringer UFO202 which plugs directly into a USB port and is immediately recognized by MacOs as a sound input and output device.

Note that this is a budget device at around $30.  If sound quality is very important to you, you need a more expensive device.

There is a review here: https://www.whathifi.com/behringer/u-phono-ufo202/review