עַל־פִּ֨י הַתּוֹרָ֜ה אֲשֶׁ֣ר יוֹר֗וּךָ וְעַל־הַמִּשְׁפָּ֛ט אֲשֶׁר־יֹאמְר֥וּ לְךָ֖ תַּעֲשֶׂ֑ה לֹ֣א תָס֗וּר מִן־הַדָּבָ֛ר אֲשֶׁר־יַגִּ֥ידֽוּ לְךָ֖ יָמִ֥ין וּשְׂמֹֽאל׃
Selon la doctrine qu’ils t’enseigneront, selon la règle qu’ils t’indiqueront, tu procéderas; ne t’écarte de ce qu’ils t’auront dit ni à droite ni à gauche.
Rashi
AS IT OVERRIDES A PROHIBITION IN THE TORAH — As it is written (Deut. 22:1) "ignore it," which excludes an elderly person where (returning the lost object) is not in keeping with his dignity [see Bava Metzia 30a]. Here, too, moving [the stones] is a rabbinic prohibition that the Sages created on the authority of [the verse] "you must not deviate" (Deut. 17:11); and [this prohibition] is pushed aside where it is in conflict with human dignity
Rabbeinu Bahya
לא תוסיפו על הדבר אשר אנכי מצוה אתכם, ולא תגרעו ממנו “do not add to the words which I command you, nor subtract from it.” This is a warning for man not to try and be smarter than G’d by saying that he will do more than G’d commanded, by thinking that the addition will be considered part of his serving the Lord. This is why Moses had to point out that the Torah is perfect. Not only does it not need additions or subtractions but any addition is in fact a subtraction (Sanhedrin 29). Our sages in Sifri Re'ay 82 quote examples of what the Torah means by additions or subtractions. If someone were to take five paragraphs from the Torah and place them inside the phylacteries of the head, doing so deliberately as an addition to what the sages said, or if he were to present G’d with five species of plants on the festival of Sukkot, instead of the four species mentioned in the Torah, or if a priest were to add a fourth verse to the three verses which form the priestly blessing, such a person would be guilty of violating this commandment.
On the other hand, if someone adds to the various Rabbinic “laws” instituted to protect Biblical laws against infringement and violation by the ignorant, such additions do not qualify as a violation of the commandment Moses speaks about here. Any Rabbinic ordinance introduced for the sole purpose of ensuring the observance of the Torah law as it is and protecting it against violation is not called “an addition.” It is in the nature of a fence around a vineyard, something that does not contribute to or enlarge the vineyard but merely protects it against thieves, marauders, etc. The classic Talmudic example for this is found in Shabbat 13 where the sages are quoted as encouraging a Nazirite to detour around a vineyard. It is not forbidden for a Nazirite to walk through a vineyard. However, if he does not walk through it it will be easier for him to resist the temptation of taking and eating from its grapes, something absolutely forbidden to him by Torah law. In fact, not only does observing the Rabbinic ordinances not constitute a violation of the commandment not to add to the Torah’s laws, but violating Rabbinic ordinances violates a specific Torah commandment of “do not depart from the word that they tell you right or left.” The “they” are the duly authorized Rabbis (Deut, 17,11).
On the other hand, if someone adds to the various Rabbinic “laws” instituted to protect Biblical laws against infringement and violation by the ignorant, such additions do not qualify as a violation of the commandment Moses speaks about here. Any Rabbinic ordinance introduced for the sole purpose of ensuring the observance of the Torah law as it is and protecting it against violation is not called “an addition.” It is in the nature of a fence around a vineyard, something that does not contribute to or enlarge the vineyard but merely protects it against thieves, marauders, etc. The classic Talmudic example for this is found in Shabbat 13 where the sages are quoted as encouraging a Nazirite to detour around a vineyard. It is not forbidden for a Nazirite to walk through a vineyard. However, if he does not walk through it it will be easier for him to resist the temptation of taking and eating from its grapes, something absolutely forbidden to him by Torah law. In fact, not only does observing the Rabbinic ordinances not constitute a violation of the commandment not to add to the Torah’s laws, but violating Rabbinic ordinances violates a specific Torah commandment of “do not depart from the word that they tell you right or left.” The “they” are the duly authorized Rabbis (Deut, 17,11).
Rashi
A PROHIBITION IN THE TORAH — the negative commandment of "you must not deviate" (Deut. 17:11), as it does here.