The thin strands you're talking about are byssal threads which are produced by the byssal gland, thats not its foot

. The clam produces those to help adhere themselves to a surface so they can stay upright. They are able to release those threads at any time. If you want the clam to remain on the rock, just right it in the same position it was in before. If it is continually falling on its side, perhaps place it on a more stable, sheltered area or on the sand. If you put it on the sand, place an empty snail shell or small piece of rock underneath in the sand so it can adhere to that
