Thank you for reading
local Part = game.Workspace.Part
local holdingUKey = false
local UIS = game:GetService("UserInputService")
UIS.InputBegan:Connect(function(inputObject)
if(inputObject.KeyCode==Enum.KeyCode.E)then
holdingUKey = true
while holdingUKey do
Part.CFrame = CFrame.Angles(0,1,0)*Part.CFrame
wait(0.001)
end
end
end)
UIS.InputEnded:Connect(function(inputObject)
if(inputObject.KeyCode==Enum.KeyCode.E)then
holdingUKey = false
end
end)

3 comments
If you don't know, a circle is made up of three-sixty degrees which is the same as two pi radians.
It is still doing it it is rotating in a full circle I just want it to turn like when you rotate in roblox studio
The average reaction time is 250 ms while your script waits for only 1 ms. By the time the player stops pressing the key, he will have rotated atleast 250 degrees. Try waiting for longer maybe one tenth of a second, so you move ten degrees in a second.