You can do 1 of these things to prevent it:
1. After removing the water, insert a chunk of butter or
olive-oil and mix it together.
2. before inserting the pasta in the boiling water, insert
olive-oil and only then insert the pasta.
I like way number 1 better (also tastes better
)