There's a sensor on the top left, just by the speaker. You might be getting debris on it, so just wipe it clean with your shirt and the sensor won't be so....sensitive.
You may be able to turn it off completely in the Settings> Call Settings or whatever it is called. It should be called "proximity sensor" which is responsible for turning the screen off when it senses darkness (of your cheek when the phone is next to it) so you don't end up hitting any buttons while talking (like the dialer or "End Call").
That should fix it. If I'm on a call and I need to do something, I hit the "Home" key just to make sure I get to the Home screen and then do what I have to do from there. No screen turning off crap.