Encoder question

I'm wondering if this can take 4-5000 RPM.

Of course not. It is intended for a hand-twisted knob.

You will need a ball bearing, industrial quality shaft encoder, intended for operation at high RPMs. Here is one selection guide. eBay sometimes has good deals on used ones.

You will need to decide the angular resolution of the encoder (how many counts per shaft revolution), keeping in mind that the Arduino is not very fast.