How to limit inbound call duration

I want to put a limit on the length of a phone call, specifically inbound calls.
I modified extensions_custom.conf file:
exten => _X.,1,noop(Limiting maximum call duration)
exten => _X.,n,Set(TIMEOUT(absolute)=10)
and more than
But it don’t work.
Pls help me to resolve.
this is a freepbx system
Asterisk 11