Yes. A magnet is fussy about what it will hold on to. It sticks only to objects made of a few special materials — mainly iron, and also nickel and cobalt (and mixtures such as steel that contain them).
Magnet + steel U-clip → sticks
Magnet + wooden pencil → does not stick
Magnet + rubber eraser → does not stick
So the test is not “is it hard?” or “is it shiny?” or even “is it a metal?”. A copper wire and an aluminium foil are metals, yet a magnet ignores both. What matters is which metal it is.